Programming Problem 1. Rock, Paper, Scissors This is your traditional rock-paper-scissors game, where two players select one of the three options and a result is produced based on their selection. For reference: Rock beats scissors Paper beats rock Scissors beats paper For this problem, you are to assume that two human players will play against each other and will input their choices accordingly. The input for each player will be in the form of buttons. Once a player clicks on a button, the rest of their buttons are locked in place (i.e. disabled). Once the other player selects their pick, the program outputs who won or if there was a draw. This isn’t exactly the most realistic way to code the game as it would be better if both players made their choice at the same time, but we’ll just have to chalk this up as a limitation for our exam. Aside from the game itself, the program should track the score of each player. Basically, if one wins, that player’s score goes up by one. When a draw occurs, neither players’ score increments.

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter5: Control Structures Ii (repetition)
Section: Chapter Questions
Problem 27PE
icon
Related questions
Question

Computer Science

Godot Programming

 

Programming Problem 1. Rock, Paper, Scissors This is your traditional rock-paper-scissors game, where two players select one of the three options and a result is produced based on their selection. For reference: Rock beats scissors Paper beats rock Scissors beats paper For this problem, you are to assume that two human players will play against each other and will input their choices accordingly. The input for each player will be in the form of buttons. Once a player clicks on a button, the rest of their buttons are locked in place (i.e. disabled). Once the other player selects their pick, the program outputs who won or if there was a draw. This isn’t exactly the most realistic way to code the game as it would be better if both players made their choice at the same time, but we’ll just have to chalk this up as a limitation for our exam. Aside from the game itself, the program should track the score of each player. Basically, if one wins, that player’s score goes up by one. When a draw occurs, neither players’ score increments.

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
Mathematical functions
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning