subject

Write a function that plays the popular scissor-rock-paper game. (A scissor can cut a paper, a rock can knock a scissor, and a paper can wrap a rock.) Function prototype: void gameOfScissorRockPaper(int) The function randomly generates a number 0, 1, or 2 representing SCISSOR, ROCK, and PAPER. It prompts the user to enter a number 0, 1, or 2 and displays messages indicating the choices from the user and computer, whether the user or the computer wins, loses, or draws. If the user enters an invalid choice, prompt an error message, and ask to re-enter the choice. The function takes one int argument specified how many FIRST wins from the computer or the user to win the game. It will let the user continuously play until either the user or the computer wins. Use enum to define Inputs values as below to check the user's input in your program,

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 16:30
Primary tech skills are skills that are necessary for success in online education
Answers: 3
question
Computers and Technology, 23.06.2019 04:10
2pointswho was mikhail gorbachev? oa. a russian leader who opposed a coupob. a polish leader who founded the labor union "solidarityoc. a soviet leader who called for a closer relationship with the unitedstates, economic reform, and a more open societyd. a soviet leader who called for more oppression in the soviet union
Answers: 3
question
Computers and Technology, 24.06.2019 16:00
To fill (copy) a cell across or down, point to the of the cell and drag. top left corner top right corner bottom left corner bottom right corner
Answers: 3
question
Computers and Technology, 25.06.2019 05:30
In our new car, we were able to drive 30 miles in a half an hour. from this information, we can determine the car's a. acceleration. b. velocity. c. speed. d. direction.
Answers: 1
You know the right answer?
Write a function that plays the popular scissor-rock-paper game. (A scissor can cut a paper, a rock...
Questions
question
Mathematics, 03.03.2021 01:00
question
Mathematics, 03.03.2021 01:00
question
Mathematics, 03.03.2021 01:00
question
History, 03.03.2021 01:00
question
Mathematics, 03.03.2021 01:00
question
Mathematics, 03.03.2021 01:00
question
Mathematics, 03.03.2021 01:00
question
Mathematics, 03.03.2021 01:00