keep_going = 'yes' lost = 0 won = 0 drawn = 0 game_mode = 'over' computer_lost = 0 computer_won = 0 computer_drawn = 0 x_of_games = 0 no = 1 rounds = 0 computer_play = 0 game_mode = input('which game mode do you want? infinte/firsttox ') while game_mode== 'infinte': while keep_going =='yes': play = input("rock paper or scissors? ") import random #random.randrange computer_play = random.randrange(1,4) if computer_play == 1 : computer_play = 'rock' print('rock') elif computer_play == 2: computer_play = 'paper' print('paper') elif computer_play == 3: computer_play = "scissors" print("scissors") if play == 'rock': if computer_play == 'paper' : print ("you lose shame") lost += 1 if play == 'rock': if computer_play == 'scissors' : print('you win') won += 1 if play == 'paper': if computer_play == 'scissors' : print ("you lose shame") lost += 1 if play == 'paper': if computer_play == 'rock' : print('you win') won += 1 if play == 'scissors': if computer_play == 'rock' : print ("you lose shame") lost += 1 if play == 'scissors': if computer_play == 'paper' : print('you win') won+=1 if play == computer_play : print('you tie, try again') drawn+=1 else: keep_going = input("Do you want to play again? ") if keep_going == 'no': game_mode = 'over' while game_mode == 'firsttox': x_of_games = int(input('first to what? ')) while keep_going == 'yes': play = input("Rock paper or scissors? ") import random # random.randrange computer_play = random.randrange(1, 4) if computer_play == 1: computer_play = 'rock' print('rock') elif computer_play == 2: computer_play = 'paper' print('paper') elif computer_play == 3: computer_play = "scissors" print("scissors") if play == 'rock': if computer_play == 'paper': print("you lose shame") lost += 1 computer_won += 1 if play == 'rock': if computer_play == 'scissors': print('you win') won += 1 computer_lost += 1 if play == 'paper': if computer_play == 'scissors': print("you lose shame") lost += 1 computer_won += 1 if play == 'paper': if computer_play == 'rock': print('you win') won += 1 computer_lost += 1 if play == 'scissors': if computer_play == 'rock': print("you lose shame") lost += 1 computer_won += 1 if play == 'scissors': if computer_play == 'paper': print('you win') won += 1 computer_lost += 1 if play == computer_play: print('you tie, try again') drawn += 1 computer_drawn += 1 if won >= x_of_games: keep_going = 'no' game_mode = 'over' if computer_won >= x_of_games: keep_going = 'no' game_mode = 'no' rounds = won + lost + drawn score = won - lost print('End of game') print (f'Score: {score}') print(f'Game Stats: Won = {won} Drawn = {drawn} Lost = {lost}') print(f'Rounds: {rounds}')