wrote a program that comes out of the number from 1 to the introduced number, and the player must be guessing it, but Syntaxerror gives it to check the introduced number. What do I do wrong?
from random import randint
TOP = INT (INPUT ('INPUT A HIGHESTIN POSSIBLE NUMBER.'))
RAND_NUMBER = RANDINT (1, TOP)
ATTEMPT = 0.
While 1 == 1:
Guess = (Input ('Input Your Guess.')
IF 1 & GT; Guess or Guess & GT; Top: # If the Guess is outside [1, Top], it starts errors.
Print ('Are You Giving Up? Y / N')
ANSWER = INPUT ()
IF Answer in ['N', 'N', 'NO', 'NO', 'NO']:
Print ("OK, We Are Back to the Game!")
Continue.
ELSE:
PRINT ('GAME OVER')
Break
Answer 1, Authority 100%
Guess = (Input ('Input Your Guess.')
Lack of brackets
Answer 2, Authority 25%
from random import randint
TOP = INT (INPUT ('INPUT A HIGHEST POSSIBLE NUMBER:'))
RAND_NUMBER = RANDINT (1, TOP)
ATTEMPT = 0.
While True:
Guess = Int (Input: 'Input Your Guess:'))
IF Guess Not in Range (1, Top):
answer = input ('Are You Giving Up? Y / N')
If Answer.Lower () In ('N', 'No'):
Print ("OK, We Are Back to the Game!")
Continue.
elif answer.lower () in ('y', 'yes'):
PRINT ('GAME OVER')
Break