Which of the following statements is true about data files in C programming?
16 views
- Data files are used to store executable code
- Data files are stored in memory
- Data files can be read and written using file pointers (Correct Answer)
- Data files can only be accessed in read-only mode
Explanation
Answer: c) Data files can be read and written using file pointers
Explanation: Data files in C programming are used to store data persistently on disk. They are not used to store executable code. Data files are not stored in memory; they are read from and written to disk. File pointers are used to access data files in C programming. File pointers provide a way to read and write data from and to data files. Data files can be opened in read-only mode or write-only mode, or both read and write modes.