The most frequently used read/write stream is iostream. We'll look at the implementation shortly.

The stream classes std::istream and std::ostream are often used for the reading and writing of data. Use of std::istream classes requires the <istream> header; use of std::ostream classes requires the <ostream> header. We can have both with the header <iostream>. std::istream is a typedef for the class basic_istream and the character type char whereas std::ostream is a typedef for the class basic_ostream:

Get hands-on with 1200+ tech skills courses.