Author | test |
Submission date | 2012-11-17 19:57:29.140532 |
Rating | 3170 |
Matches played | 767 |
Win rate | 32.86 |
Use rpsrunner.py to play unranked matches on your computer.
if input == "": # initialize variables for the first round
rockCount = paperCount = scissorsCount = 0
if rockCount > paperCount and rockCount > scissorsCount:
rockCount = rockCount + 1
output = "P" # paper beats rock
elif paperCount > scissorsCount:
scissorsCount = scissorsCount + 1
output = "S" # scissors beats paper
else:
paperCount = paperCount + 1
output = "R" # rock beats scissors