RosettaCodeData/Task/Guess-the-number/Python/guess-the-number-1.py
2023-07-01 13:44:08 -04:00

5 lines
162 B
Python

import random
t,g=random.randint(1,10),0
g=int(input("Guess a number that's between 1 and 10: "))
while t!=g:g=int(input("Guess again! "))
print("That's right!")