Tic tac toe C++ overwriting the board
Tic tac toe C++ overwriting the board Hi so I have it set up the way I want to for the most part. The last part I'm trying to implement is to have it so the input does not overwrite itself when input either X or 0 . If someone could take a look at it and tell me what exactly I did wrong with my noRepeat function I would greatly appreciate it. Thanks. X 0 #include <iostream> using namespace std; const int ROWS = 3; const int COLS = 3; char Player1 = 'X'; char Player2 = 'O'; int row, col; char board[3][3]= { '*', '*', '*', '*', '*', '*', '*', '*', '*'}; //Game board //Prototypes void noRepeat(); void drawBoard(); void selection(int&, int&); char winner(); void switchPlayer(); int main() { cout << "Tic Tac Toe!" << endl << endl; drawBoard(); cout << endl << endl; while (1) { if ( noRepeat() ) { ...