Jan-22-2017, 05:40 PM
import random secret_num = random.randrange(1, 10) while True: number = int(input("Guess a number between 1 and 10: ")) if number == secret_num: print("You guessed right!") breakI want to the program to say "You did not enter a number!" if there is a value error, for example if the user types in a letter or something else that usually makes the program shut down. I know you can use exceptions but I just can't make it work when I try to use them. Please help a newbie programmer out
