Exam-style question
Try this first
Understanding file operations in programming.
Description
File Operations
File operations include opening, closing, reading, and writing files. Each operation has specific purposes and must be executed in the correct order to avoid errors.
- a[2]
Explain the importance of closing a file after operations are completed.
Aim for approximately 2 distinct marking points.
0 of 1 part answered
Answer every part before opening the mark scheme.
Concise answer preview
Concise answer
Closing a file is important because it saves all changes made to the file and frees up system resources that were being used.
Why this is correct
Properly closing a file ensures that all data is saved and that the program does not hold onto resources unnecessarily.
Complete every part above to unlock the full mark scheme through the existing protected review flow.
Common mistake
No common mistake is linked to this question yet.
