import random score = 0 answer = "y" while answer != "n": dice1 = random.randint(1, 6) dice2 = random.randint(1, 6) if dice1 + dice2 == 2: score += dice1 + dice2 print(score) answer = input("Play again? y/n: ") else: print("Snake-eyes! You'll lose!") answer = "n" score = 0 print("Thanks for playing!")