CBSE Class 12 Binary Files (Chapter 4B) (2026) 1-Mark Board Question Q10
Official CBSE Marking Scheme Solution
Option B — rb is read-only binary mode; r is the text read-only mode.

Authentic CBSE board questions & official stepwise marking scheme solutions for Binary Files (Chapter 4B).
Board examination questions on binary serialization using the pickle module: pickle.dump(), pickle.load() inside sequential loops, EOFError handling, and record searching and modification.
Key Topics: pickle Module, pickle.dump() & pickle.load(), EOFError Handling, Searching Binary Records, Updating Serialized Data
CBSE Class 12 Binary Files (Chapter 4B) (2026) 1-Mark Board Question Q10
Option B — rb is read-only binary mode; r is the text read-only mode.

CBSE Class 12 Binary Files (Chapter 4B) (2026) 5-Mark Board Question Q36
import pickle def Append(): with open("RESOURCES.DAT", "ab") as f: rec = (int(input("RID: ")), input("Name: "), input("Expertise: "), int(input("Charges: "))) pickle.dump(rec, f) def Update(): records = [] try: with open("RESOURCES.DAT", "rb") as f: while True: records.append(pickle.load(f)) except EOFError: pass with open("RESOURCES.DAT", "wb") as f: for rid, name, expertise, charges in records: pickle.dump((rid, name, expertise, charges + 500), f)

CBSE Class 12 Binary Files (Chapter 4B) (2025) 1-Mark Board Question Q20
Assertion is true; reason is false. pickle.dump writes data to a binary file, so rb mode is not writable.

CBSE Class 12 Binary Files (Chapter 4B) (2025) 5-Mark Board Question Q36
import pickle def Create(record): with open("PASSENGERS.DAT", "ab") as f: pickle.dump(record, f) def SearchDestn(D): try: with open("PASSENGERS.DAT", "rb") as f: while True: r = pickle.load(f) if r[3] == D: print(r) except EOFError: pass # UpdateFare: load all records, multiply r[4] by 1.05, then rewrite the records.

CBSE Class 12 Binary Files (Chapter 4B) (2023) 4-Mark Board Question Q35
Statement 1: open("Cust_file.dat", "ab") Statement 2: qty < 10 Statement 3: pickle.dump(c_detail, bin_file) Statement 4: break Statement 5: bin_file.close() Statement 6: write_bin() 2023 direct MCQs

Functions & Exception Handling • Text Files • Binary Files • CSV Files • Stack • Computer Networks • Database Concepts & SQL • Python-MySQL Connectivity