0% found this document useful (0 votes)
303 views1 page

Rock Paper Scissors Flowchart

The document is a flowchart detailing the logic for a 10-game Rock-Paper-Scissors game between a user and the computer. It describes the initialization of variables, the process of generating computer choices, user inputs, and the conditions for winning, tying, or losing. The flowchart concludes by displaying the final scores after 10 games have been played.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
0% found this document useful (0 votes)
303 views1 page

Rock Paper Scissors Flowchart

The document is a flowchart detailing the logic for a 10-game Rock-Paper-Scissors game between a user and the computer. It describes the initialization of variables, the process of generating computer choices, user inputs, and the conditions for winning, tying, or losing. The flowchart concludes by displaying the final scores after 10 games have been played.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
You are on page 1/ 1

Rock-Paper-Scissors Flowchart

This flowchart outlines the logic for a 10-Game


Rock-Paper-Scissors Game between
a user & the computer.

Start

Initialize variables:
userWins = 0, comWins = 0,
ties = 0, game = 0,
“Rock”=1, ”Paper”=2,
”Scissors”=3,

Start Game

Input Computer Choice: Display message: "Enter your


“Generate a random choice: ”
number between 1, 2 Rock(1), Paper(2), Scissors(3)
& 3"

Increment Input User


game by 1 Choice

Com = User

No
Yes
Com (1) &
User (2)

No
Yes
Com (2) &
User (3)
Yes
No

Com (3) &


Yes
User (1)

No

Display message:
Display message: Display message:
"Computer win this
"You win this round!" "It's a tie!"
round!"

Increment Increment Increment


comWins by 1 userWins by 1 ties by 1

game = 10 No

Yes

Display message:
"You won =" + userWins
“Computer won = " + comWins
“Ties = " + ties

End

You might also like