// loadfile.h // This is the header file to include to load files for // hangman // Copyright (c) 1998 Forest J. Handford /////////////////////////////////////////////////////// #include // For input/output #include // For file input/output #define MAX_WORD_SIZE 15 // The max size for words #define MAX_WORDS 255 // The max number of words typedef char String[MAX_WORD_SIZE]; // The typedef for string String Words[MAX_WORDS - 1]; // This array will hold our words int Count; //word count // This will load our file void LoadFile() { char C; //Used to find EOF ifstream Datfile; //The in file Count=0; //Set count to 0 // Open the data file Datfile.open("words.dat"); //Loop till the end of file while((C=Datfile.peek()) != EOF) { // Get the next word and then increment Count Datfile>>Words[Count++]; // If we surpass the max exit and tell the user if(Count > MAX_WORDS - 1) { cout<