Question: only want the pseudocode for this question and also explained . Tic-tac-toe also known as noughts and crosses or Xs or Os, is a paper

only want the pseudocode for this question and also explained .
only want the pseudocode for this question and also explained . Tic-tac-toe

Tic-tac-toe also known as noughts and crosses or Xs or Os, is a paper and pencil game for two players, X and 0 , who take turns marking the spaces in a 33 grid. The player who succeeds in placing three of their marks in a horizontal, vertical, or diagonal row wins the game. The strategy in the game can be simple, like trying to block the opponent or it can be more complex, like trying to set a trap for the opponent. Instructions Pseudo-code (20 pts) Convert the pseudocode to do the following task: 1. Create a 33 grid to start the Tic Tac Toe game. 2. Players decide who will go first using rock-paper-scissors. The winner is determined by the rules below: a. Rock beats scissors (rock crushes scissors) b. Scissors beat paper (scissors cut paper) c. Paper beats rock (paper covers rock) d. If both players throw the same shape, restart the rock-scissors-paper decision. 3. Player 1 marks an ' X ' on an empty square. 4. Player 2 marks an ' O ' on an empty square. 5. Players take turns marking their respective symbol in an empty square. 6. Check if one player has won or if the game is a draw after each turn. 7. If one player wins, the game is over, and the player is declared the winner. 8. If the grid is filled and no player has won, the game is a draw. 9. Start a new game or end the game

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!