Opening and Closing Files — Study Resources & PYQs
Opening, accessing and closing files in C.
- Estimated study time: 30 minutes
Study resources
- C File Handling - Programiz (Article) — Complete file I/O walkthrough: fopen with its access modes, fprintf, fscanf, fread, fwrite, fseek and fclose, with a working example that creates a real file. The best single page for this topic.
- C File Pointer - GeeksforGeeks (Article) — Explains what the FILE pointer actually is, which fopen returns and fclose releases. Read alongside the Programiz page above.
Opening and Closing Files previous year questions
- a) How is data file opened in 'C'. Describe various modes of opening a data file. (10) b) Explain file handling. Write a program to create a file and display i…
- (a) Describe various modes of opening a data file in C. (06) (b) Different between the following (i) fread( ) and fscanf( ) (ii) fwrite( ) and fprintf( ) (iii)…
Taught in these subjects
- COMPUTER PROGRAMMING — BCST11 · Government College of Engineering and Technology, Jammu
- Computer Programming — CST3101 · Government College of Engineering and Technology, Jammu