All pastes #442193 Raw Edit

Stuff

public text v1 · immutable
·published 2007-04-16 02:03 UTC
rendered paste body
#include <iostream>
#include <string>
#include <fstream>

using namespace std;

void readMenu(ifstream& theMenu);


int main(void)
{
	readMenu( displayMenu );

	return 0;
}

void readMenu(ifstream& theMenu)
{
		
	string line;
	ifstream displayMenu;
	displayMenu.open("Menu.txt");
	
	if ( displayMenu.is_open())
	{
		while ( !displayMenu.eof() )
		{
			 getline (displayMenu,line);
			 cout << line << endl;
		}
	}
	else
	{
		cerr << "The Machine is Empty" << endl;
		exit(100);
	}
	readMenu(displayMenu);
	displayMenu.close();
}