In C++, how do you check if a file has reached the end while reading?
A. file.eof()
B. eof(file)
C. file.end_of_file()
D. endOfFile(file)
Answer: Option A
Related Questions on File Handling in C plus plus
Which header file is required for file handling in C++?
A. <iostream>
B. <fstream>
C. <file>
D. <filestream>

Join The Discussion