subject

Write a sixth game program that can play tic tac toe. This game displays the lines of the tic tax toe game and prompts the player to choose a move. The move is recorded on the screen and the computer picks his move from those that are left. The player then picks his next move. The program should allow only legal moves/. The program should indicate when there is a winner and tell who won. The player is then asked if he would like to play again. If the game is played the second time the computer is first to move. The player and computer take turns being first' player is then asked if he would like to play again. A sample output is shown in the attached file.
Tic_tac_toe game This game is played between you and the computer.
You move first and the computer will then move.
Play continues until you or the computer wins or it is a "cat's" game.
1 2 3
A ___|___|___
B ___|___|___
C | |
Please enter your move.
a1
1 2 3
A _X_|___|___
B ___|___|___
C | |
Computer makes a move.
1 2 3
A _X_|_O_|___
B ___|___|___
C | |
Please enter your move. b2
1 2 3
A _X_|_O_|___
B ___|_X_|___
C | |
Computer makes a move.
1 2 3
A _X_|_O_|___
B ___|_X_|___
C | | O
Please enter your move.
b1
1 2 3
A _X_|_O_|___
B _X_|_X_|___
C | | o
Computer makes a move.
1 2 3
A _X_|_O_|___
B _X_|_X_|___
C o | | O
Please enter your move.
b3
Congratulations you won!!
1 2 3
A _X_|_O_|___
B _X_|_X_|_X_
C o | | O
Would you like to play Tic-Tac-Toe again?
(yes/no)
Game 6 - due date FiveDigitNumber class - Write a sixth game program using the random number generator to generate a five-digit number. The player guesses the number. With each guess the computer returns two numbers, the first is the number of digits that are in the proper position and the second is the sum of the correct digits. Allow the client to repeat the game as many times as she wishes. Guarantee the numbers entered are 5 digit numbers. A sample output is shown in the attached file.
Using the random number generator, this game creates a
five-digit number. The player guesses the number.
The computer returns two numbers, the first is the number
of digits that are in the proper position and the second
is the sum of the correct digits guessed so far.
The player continues guessing untill she gueses the correct number.
Please enter the number you would like to guess.
24834
You have found 1 digits so far with a sum of 8.
Please enter the number you would like to guess.
26845
You have found 2 digits so far with a sum of 14.
Please enter the number you would like to guess.
56856
You have found 3 digits so far with a sum of 19.

Please enter the number you would like to guess.
56867
You have found 3 digits so far with a sum of 19.
Please enter the number you would like to guess.
56878
You have found 3 digits so far with a sum of 19.
Please enter the number you would like to guess.
56889
You have found 4 digits so far with a sum of 27.
Please enter the number you would like to guess.
56880
It took 7 guess to get the number 56880.
Would you like to play the game again?
Please enter (yes/no)

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 22:30
Ted wants to go out to a neighborhood park and shoot pictures of dew drops on grass. he wants to get a low-level angle of the dew drops. which support equipment should ted use? a. mini tripod b. pistol grip c. monopod d. body mount
Answers: 2
question
Computers and Technology, 22.06.2019 08:50
Can online classes such as gradpoint track your ip location like if im taking a final and i give somebody else my account and they take the final for me will it show where they are taking the final from? and can this be countered with a vpn
Answers: 1
question
Computers and Technology, 22.06.2019 13:00
Which option should u select to ignore all tracked changes in a document
Answers: 1
question
Computers and Technology, 22.06.2019 16:00
You have inserted new slides based on a word outline. how do you format these new slides to match the powerpoint presentation formatting? a. select all slides in the presentation and click format on the home tab. b. select the new slides and click reset on the home tab. c. select all slides in the presentation and click reset on the home tab. d. select the new slides and click format on the home tab.
Answers: 3
You know the right answer?
Write a sixth game program that can play tic tac toe. This game displays the lines of the tic tax to...
Questions
Questions on the website: 13722363