Making a Game for a school project and Im using a 2D array to make the gameboard. Well in the begginning of the game the user has to input what the current game board looks like. I have it so the user is entering data and the data is being entered into the array,but the newline character at the end of each input is missing it up,here is the portion of code Im working with atm.
char board;
int a = 6,i = 6;
cout << " Please enter what the board looks like: "<<endl;
cin.get(board);
while(cin)
{
cout<<"board is ="<<board<<"and going into position"<<a<<i<<endl;
/*
if(board == ' ')
gameBoard[a][i] = ' ';
else
gameBoard[a][i] = board;
*/
if(i>0)
{
i--;
}
else
{
a--;
i = 6;
}
cin.get(board);
}