Miscellany
public text v1 · immutable#include <iostream.h>
#include <fstream.h>
#include <stdlib.h>
int main ()
{
char buffer[256];
ifstream gamefile ("gamefile.txt");
if (! gamefile.is_open())
{
cout << "Error opening file";
exit (1);
} while (! gamefile.eof() )
{
gamefile.getline (buffer,100);
cout << buffer << endl; } return 0;
}