A program reads struct records using fread(). After reading 100 records of 64 bytes each, what is the total bytes read if successful?
Which statement correctly counts non-comment lines in a text file?
In a program processing a CSV file, what is the most robust approach for reading variable-length lines?
A file opened with 'r+b' mode has pointer at position 100. After fwrite(buffer, 1, 50, fp), the pointer is at:
Which approach correctly implements a file copy function for both text and binary files?
Advertisement
A program crashes after reading a file. What's most likely the cause if error checking is minimal?
For a file with 1000 records, which approach minimizes I/O operations?
A program needs to read and write to the same file alternately. Which file mode is most appropriate?
What will be the output of fseek(fp, -10, SEEK_END) in a file of 100 bytes?
In a data structure serialization scenario, what is returned by fwrite() on successful completion?
A competitive exam question requires processing a 500MB CSV file line by line. Which approach is most efficient in terms of memory?
What is the critical issue if ferror(fp) returns non-zero during file operations in a banking application?