Created
August 3, 2016 21:57
-
-
Save kevin-weitgenant/f03614d896d950839454c0707ea0e70e to your computer and use it in GitHub Desktop.
practicepython.org Exercise 09
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import random | |
a = random.randint(1, 9) | |
x = "" | |
while x != "exit": | |
user_number = int(input("Choose a number between 1 and 9:")) | |
if a > user_number: | |
print("Too low!") | |
elif a < user_number: | |
print("Too High!") | |
else: | |
print("You're goddamn right!") | |
x = input("exit to leave, any key to try again") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment