Computer Programming class c 1 What is the name of a library
Computer Programming class (c++)
(1) What is the name of a library you must include in your program when you access files? (4 points)
(2) What is the name of a type for declaring input file stream? (3 points)
(3) What is the name of a type for declaring output file stream? (3 points)
Solution
1>Name of a library you must include in your program: fstream
Before a file stream can be used for I/O, it must be declared just as you would declare any other variables.
2>The type for input file stream variables is ifstream.
3>The type for output file stream variables is ofstream.
