Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void initialBoard(char b[NUM_ROWS][NUM_COLS])
- {
- int row, col;
- ifstream inputFile;
- inputFile.open("board.txt");
- /*if(!inputFile)
- {
- cout <<"Error Finding board.txt"<<endl;
- system("pause");
- exit(-1);
- }
- */
- //Reads in a text file, and initializes board to all '.'
- for(row=0;row<NUM_ROWS;row++)
- {
- for(col=0;col<NUM_COLS;col++)
- {
- inputFile>>b[row][col];
- //b[row][col] = '.';
- }
- }
- inputFile.close();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement