Question: C++: This is a program that needs to play rocks papers scissors and loops until you decide to use the quit option. Thank you so

C++: This is a program that needs to play rocks papers scissors and loops until you decide to use the quit option. Thank you so much!

C++: This is a program that needs to play rocks papers scissorsand loops until you decide to use the quit option. Thank you

1) Write a function getUserChoice that displays the menu and validate the choice: Game Menu 1) Rock 2) Paper 3) Scissors 4) Quit Enter your choice (1-4): //If the user enters 4, the program should end. 2) Write a function getComputerchoice, When the program begins, a random number in the range of 1 through 3 is generated. The user enters his or her choice of "rock", "paper", or "scissors" at the keyboard. 3) Write a function displayChoice to display the user's choice and computer's choice 4) Write a function determineWinner to displays a message indicating the winner. This should be made based around the actual rules of Rocks, Papers, Scissors. Have the game be repeated after each round, whether there is a winner, loser or a tie.| Input Validation: Display an error message if the user enters a number outside the range of 1 through 4 when selecting an item from the menu. e Output: Assignment \#3 by John Smith Game Menu 1) Rock 2) Paper 3) Scissors 4) Quit Enter your choice: 2 You selected: Paper The computer selected: Paper Tie. No winner. Game Menu 1) Rock 2) Paper 3) Scissors 4) Quit Enter your choice: 3 You selected: Scissors The computer selected: Paper YOU win! Paper wraps scissors. Game Menu 1) Rock 2) Paper 3) Scissors 4) Quit Enter your choice: 2 You selected: Paper The computer selected: Scissors Computer wins! Paper wraps scissors. Game Menu 1) Rock 2) Paper 3) Scissors 4) Quit Enter your choice: 4 Press any key to continue

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!