Computer Science, asked by dhanushDhanush820, 1 year ago

name the streams generally used for file i/o

Answers

Answered by OmkarT
0
The stream we use for i/o is iosteam.
i.e input-output stream

Eg:header file
#include<iostream.h>
Answered by pritishakalita
3

Answer:

the streams generally used for I/O are :

(1) ifstream

(2)ofstream

(3)fstream

Explanation:

(1) ifstream is derived from istream class and it is used to associate a file with an input buffer so that the file can be read from.

(2) ofstream is derived from ostream class and it is used to associate a file with an output buffer so that the file can be written onto.

(3) fstream is derived from iostream class and it is used to associate a file with a buffer so that the file can be read from as well as written onto.

(Source: Computer Science textbook for class XII by Sumita Arora. The chapter is Data File Handling)

Similar questions