Complete Summary and Solutions for File Handling in Python – NCERT Class XII Computer Science, Chapter 2 – Text Files, Binary Files, Opening, Closing, Reading, Writing, Pickle Module, Questions, Answers

Detailed summary and explanation of Chapter 2 'File Handling in Python' from the Computer Science textbook for Class XII, covering types of files (text and binary), file opening and closing modes, reading and writing operations, file pointer functions (seek and tell), pickling and unpickling with the pickle module, and practical examples—along with all NCERT questions, answers, and exercises.

  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 35 marks: Calculus, shared with Part II
  • 10 marks: Algebra, Ch 3–4
  • Common traps that cost marks, listed
  • 6 principal branches of inverse trig
  • Every derivative rule with its condition
Browse all 46 kits →
Complete Summary and Solutions for File Handling in Python – NCERT Class XII Computer Science, Chapter 2 – Text Files, Binary Files, Opening, Closing, Reading, Writing, Pickle Module, Questions, AnswersOpen the full article →
Full Chapter Summary & Detailed Notes - File Handling in Python Class 12 NCERT works on the full page only.Open it →

CBSE Class 12 Board Examination kits

  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 35 marks: Calculus, shared with Part II
  • 10 marks: Algebra, Ch 3–4
  • Common traps that cost marks, listed
  • 6 principal branches of inverse trig
  • Every derivative rule with its condition

CBSE Class 12 · Accountancy

Spreadsheet: 56 of 105 Option II marks
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 12 exam traps, listed
  • 22 of 105 marks on offer: CAS overview
  • Most asked item: error values
  • What Q27–34 ask, answer by answer
  • Every Excel function, result checked
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 23 marks in the four papers: Vector Algebra
  • Integral tables with properties P0–P7
  • 3 methods for differential equations
  • 8 marks: Probability, with Bayes' theorem
  • Patterns the board repeats, by chapter

CBSE Class 12 · संस्कृतम् (केन्द्रिकम्)

All 8 भास्वती lessons: who says what to whom
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 20 marks: grammar, 4 × 1 per part
  • Sandhi, samasa, pratyaya from the text
  • Upapada-vibhakti and vachya examples
  • Anvaya and bhavartha answer method
  • Literature intro: epics, prose, champu
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 34 marks in 4 papers: Magnetism, Ch 4–5
  • 33 marks in 4 papers: Induction and AC
  • 26 marks in 4 papers: Current Electricity
  • Every formula with its page number
  • What each 2025 board paper asked

CBSE Class 12 · संस्कृत (ऐच्छिक)

शाश्वती: where the 25 + 10 + 10 marks sit
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 15 marks: grammar from the lessons
  • 6 metres with their gana-sutras
  • 6 figures of speech (अलङ्कार)
  • 20 shlokas of रघुकौत्ससंवादः, upajati metre
  • Literary history in tables, epic to drama

CBSE Class 12 · PhysicsTrending

Ray Optics: 35 marks across four papers
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 22 marks across four papers: Wave Optics
  • 22 marks: Dual Nature, with 4-mark cases
  • Common traps that cost marks, listed
  • 13 marks each: Atoms and Nuclei
  • 7 marks in all four papers: Semiconductors

CBSE Class 12 · اردو (کور)

11 نئی آواز lessons + the board's idioms
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • Author, genre and summary, lesson by lesson
  • Verse meanings: پرچھائیاں, اپنے گھر کا حال
  • Essay, letter and precis writing
  • Map of the question paper
  • 8 common mistakes
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 7 marks each: the other four units
  • 37 of 70 theory marks across 5 units
  • Mixed traps, corrected
  • Seven board sums, worked stepwise
  • Every data table, with page numbers

CBSE Class 12 · Urdu Elective

Three translated stories, 12 book answers
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • Chekhov, Basheer and Nirmal Verma introduced
  • کلرک کی موت: 1 sneeze, 5 apologies
  • Event order and characters for each story
  • 3 stories compared in one table
  • Method for writing board answers

CBSE Class 12 · Computer Science

Files, stack, functions: Unit 1, 40 marks
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 20 marks: SQL and databases, Unit 3
  • 10 marks: Networks, Unit 2
  • 7 chapters: every output run and checked
  • Stack algorithms and output questions
  • Text, binary and CSV file programs
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 7 marks in every paper: Biomolecules
  • 6 marks in each 2025 set: Haloalkanes
  • Common traps that cost marks, listed
  • 4–5-mark question every paper: Alcohols
  • Named reactions, reagents, conditions

CBSE Class 12 · Fine Art · PaintingTrending

All 29 prescribed works: painter to medium
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 24 of 92 board marks: Bengal School
  • 20 of 92 board marks: Mughal School
  • Common traps that cost marks, listed
  • 17 of 92 board marks: Rajasthani Schools
  • 11 of 92: modern art, mostly 2-markers

CBSE Class 12 · हिंदुस्तानी संगीत (गायन / वादन)

15 gamak, 14 murchhana, three ragas
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 30 theory marks, all five units
  • Bhairav, Bageshri, Malkauns in full
  • Jhaptal, Rupak, Dhamar: dugun to chaugun
  • Sangeet Ratnakar and Parijat, by chapter
  • Tuning the tanpura and the sitar

CBSE Class 12 · Informatics Practices

Pandas: 38 of 140 board marks, mapped
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 35 of 140 board marks: SQL functions
  • 20 board marks: networks and the web
  • Common traps, corrected
  • 12 board marks: Matplotlib plots
  • Every statement with its exact output

CBSE Class 12 · Biotechnology

Beyond NCERT: 46 of 140 board marks
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 40 marks: Unit V, rDNA and genomes
  • 30 marks: Unit VI, culture and bioprocess
  • 10 syllabus chapters: every vector, enzyme
  • PCR, blots and DNA fingerprinting
  • Every number tied to its book page

CBSE Class 12 · Accountancy

All 18 ratios, with the book's answers
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 15 marks in every 2025 set: share capital
  • 9 marks in every 2025 set: debentures
  • Common traps that cost marks, listed
  • 6-mark cash flow in every paper
  • 5 marks in every 2025 set: ratios

CBSE Class 12 · सृजनात्मक लेखन और अनुवाद

सृजन 2: all 4 units, Hindi + English parts
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • Elements of a poem and a story, Unit 1
  • Feature and article writing, Unit 2
  • Radio and TV script rules, with marks
  • Steps and types of translation, Unit 3
  • Levels of editing, Unit 4

CBSE Class 12 · Business Studies

Directing: 37 marks in 4 papers, the most
  • Marks booster + cheatsheet: most-asked concepts in 2 lines each
  • 8 chapters ranked by what the board asked
  • 31 marks: Organising, a 6-marker every set
  • 30 marks in 4 papers: nature of management
  • 14 principles of Fayol
  • Case cues the board keeps using

CBSE Class 12 · हिंदुस्तानी संगीत (तबला / पखावज)

Taal notation: 20 of 60 board marks
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 16 of 60 board marks: taal comparison
  • 12 of 60 board marks: gharanas
  • 13 thekas, from thah to chaugun
  • 6 marks: history of the tabla, Unit 3
  • 4 biographies, with dates

CBSE Class 12 · Business Studies

Financial Markets: 26 marks, not in NCERT
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 15 marks each: Units 9–10 and 11–12
  • 4 Ps of marketing, Unit 11
  • Consumer Protection Act 2019 tiers, appeals
  • Capital structure with EBIT-EPS examples
  • The three financial decisions, every factor
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 10 marks: National Income Accounting
  • 3 methods for GDP, with identities
  • M1–M4 and credit creation, Ch 3
  • Every deficit measure of the budget, Ch 5
  • 6 chapters: every formula, board numerical

CBSE Class 12 · EconomicsTrending

Unit 7 (Ch 4–7) carries 20 marks
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 12 marks: Unit 6, Ch 1–3
  • 8 marks: Unit 8, India-China-Pakistan
  • Every committee, policy and date, by chapter
  • Data tables with the book's own numbers
  • Common traps, corrected
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 23 of 100 marks: Thinkers, Beliefs, Buildings
  • 22 of 100 board marks: Harappa
  • 20 of 100 marks: Kinship, Caste and Class
  • 8-mark answer: Theme 2 in 3 of 4 papers
  • 5 marks: the Part I map list
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 24 of 100 board marks: Vijayanagara
  • 24 of 100 marks: Mughal village, Theme 8
  • Q24 from Vijayanagara in every 2025 set
  • 3 of 4 papers: source question on travellers
  • 5 marks: the two map lists
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 1857 and National Movement map items
  • Constituent Assembly committees table
  • Gandhiji 1915–1931: Champaran to Salt March
  • Permanent Settlement and the Fifth Report
  • Bombay Deccan: ryotwari and the 1875 riots
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 17 of 120 marks each: industry, services
  • 15 of 120 marks: Primary Activities
  • 14 of 120 marks: Transport
  • 5 marks: world map work
  • HDI, rail and internet data as charts
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 20 board marks in 4 papers: Population
  • 14 board marks: Minerals and Energy
  • 13 of the 28 map items asked: minerals
  • 10 marks: Unit III, Ch 3–6
  • Common traps, corrected
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 18 marks: Ch 1–3, data and diagrams
  • 7 marks: GIS, Ch 4
  • Common traps that cost marks, listed
  • 5 marks: file and viva
  • Mean, median and mode, fully worked

CBSE Class 12 · English Elective

All 16 texts + what the sample paper asked
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 22 textbook marks: how each is asked
  • 3 stories: 10 marks in the sample paper
  • Common traps that cost marks, listed
  • 9 poems side by side, with devices
  • 5 essays, each argument set out

CBSE Class 12 · Political Science

End of Bipolarity: asked in all 4 papers
  • Marks booster + cheatsheet: most-asked concepts in 2 lines each
  • 6-marker in 3 of 4 papers: Security
  • 4-marker in all 4 papers: Environment
  • 6-marker in 3 of 4 papers: centres of power
  • 2 papers asked UN cartoons
  • 7 chapters: dates, treaties, leaders

CBSE Class 12 · Political Science

40 theory marks, split chapter by chapter
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 8 marks: Chapter 8, 1989 to 2019
  • 6 marks each: Chapters 1, 4 and 7
  • State-formation and war timelines
  • Party tables and election results
  • Map clues the board uses
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 10 marks for each of the four chapters
  • Demography formulas for Ch 2
  • Sex-ratio and age tables from the book
  • 10 must-know facts with a self-check
  • Common traps, corrected
  • Marks booster + cheatsheet: most-asked concepts in 2 lines each
  • 10 marks each: Units 11, 12 and 15
  • 5 marks each: Units 8 and 9
  • 4 processes of cultural change, in a table
  • Land reforms table, Chapter 4
  • Types of social movements, in one table
  • Marks booster + cheatsheet: key concepts in 2 lines each
  • 26 board marks each: Ch 1 and Ch 2
  • 22 of 140 board marks: disorders, Ch 4
  • 20 of 140 board marks: therapies, Ch 5
  • 6-mark questions on Freud, RET and Beck
  • IQ bands and twin correlations from the book
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 5 poems: Q7 is always one of these
  • 4 writing formats, 18 marks
  • Common traps, corrected
  • 8 prose pieces: events, characters, themes
  • Poetic devices with short quotes
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 12 marks: unseen passage Q1, decoded
  • 10 marks: case-based passage Q2, decoded
  • Common traps that cost marks, listed
  • Every character, with evidence and quotes
  • 7 texts: plot timelines for each

CBSE Class 12 · Home Science

Unit II nutrition and food: 23 marks
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 38 of the 70 theory marks: Ch 1–7
  • 10 marks: Unit III, ECCE to elderly
  • Common traps that cost marks, listed
  • 5 marks: Unit I, work and careers
  • 2025 paper and SQP: ranked by what they asked

CBSE Class 12 · Home Science

Ch 8–13: 32 of the 70 theory marks
  • Marks booster + cheatsheet: key concepts in 2 lines each, common traps
  • 17 marks: Unit IV Fabric and Apparel
  • 10 marks: Unit V Resource Management
  • 2025 board questions mapped to each chapter
  • Every consumer right and standard mark
  • Common traps, corrected
Browse all 46 kits →
Exam alertsGet alerts for CBSE Class 12 Board ExaminationDates, results and cutoffs, by email when they are announced. Free.Sign in to get alerts
Exam pagePreparing for CBSE Class 12 Board Examination?Syllabus, exam pattern, dates and every guide we have on CBSE Class 12 Board Examination, in one place.Open the CBSE Class 12 Board Examination page →