Examveda

What is the difference between fstream and ofstream in C++?

A. fstream can read and write, ofstream can only write

B. ofstream can read and write, fstream can only write

C. ofstream is used for text files, fstream is used for binary files

D. fstream is used for text files, ofstream is used for binary files

Answer: Option A


Join The Discussion

Related Questions on File Handling in C plus plus