No matter if I enter the correct number, it still returns “Try again”. How can I rectify this?
import random
from random import randint
num = randint(1000, 9999)
print (num)
while True:
guess = input ("Please guess a four digit number. ")
print (guess)
if guess == num:
print ("Well Done!")
else:
print ("Try again")