TicTacToeCreate the board display the board Set token to ‘x’Loop //at most 9 times, but end loop when someone wins{ Ask player where to place token display the board Checks if won Change token (if it was ‘x’ change to ‘o’ and vice versa)}Either congratulate someone on winning or say it was a draw. Create a 17x17 array of characters and put ‘ ‘ in each element.2. Write a loop to make the first horizontal line, and another to do the second horizontal line3. Write a loop to make the first vertical line, and another to create the second vertical line4. Put in the numbers (this is so the player can choose where to put the token). You will need 9 separate assignment statements.
TicTacToeCreate the board display the board Set token to ‘x’Loop //at most 9 times, but end loop when someone wins{ Ask player where to place token display the board Checks if won Change token (if it was ‘x’ change to ‘o’ and vice versa)}Either congratulate someone on winning or say it was a draw.
Create a 17x17 array of characters and put ‘ ‘ in each element.2. Write a loop to make the first horizontal line, and another to do the second horizontal line3. Write a loop to make the first vertical line, and another to create the second vertical line4. Put in the numbers (this is so the player can choose where to put the token). You will need 9 separate assignment statements.
Trending now
This is a popular solution!
Step by step
Solved in 3 steps with 6 images