We can read from a file, and we can write to a file.
The standard-library offers such functionality via file streams.
Those files streams are defined inside the <fstream> header, and they are:
The std::fstream can both read from and write to a file.