Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Stage 2 Usually one round of rock-paper-scissors is not enough. In this stage we will expand the program to play multiple rounds. Additionally, we will

image text in transcribed

Stage 2 Usually one round of rock-paper-scissors is not enough. In this stage we will expand the program to play multiple rounds. Additionally, we will make our game a bit more personable by asking each player for their name and then using the players' names in user input/output instead of "Player 1" and "Player 2". 1. 2. 3. Copy and paste the code from rock_paper_scissors_1.py to rock_paper_scissors_2.py Modify main () so that the very first thing it does is ask for the names of player 1 and player 2 from the user. Modify all of the inputs/outputs in the rest of main0 to use the players names instead of the hard- coded "Player 1" and "Player 2" strings. Before moving forward, make sure your program is working After the statements that read the players' names, add a statement that reads the number of rounds (games) to play from the users. After the statement the reads the number of rounds from the users, create a for loop that iterates the desired number of rounds. Indent all statements after the for statement one time so that they are in the body of the for loop. The body of the for loop must contain the statements that read the players' choices, calls compare, and outputs the game result. 4. 5. A run of the program must look like the following example. Make sure to change the input prompts and print statements so that the output looks like this example. The green text is user-typed input Enter name for Player 1: Rayan Enter name for Player 2: Ashley Enter number of rounds to play: 3 Enter choice for player Rayan (rock, paper, scissors):rock Enter choice for player Ashley (rock, paper, scissors): paper Ashley wins this round. Enter choice for player Rayan (rock, paper, scissors): paper Enter choice for player Ashley (rock, paper, scissors) scissors Ashley wins this round. Enter choice for player Rayan (rock, paper, scissors): rock Enter choice for player Ashley (rock, paper, scissors) scissors Rayan wins this round

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle Database 11g SQL

Authors: Jason Price

1st Edition

0071498508, 978-0071498500

More Books

Students also viewed these Databases questions

Question

The paleolithic age human life, short write up ?

Answered: 1 week ago