Input programm error | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Input programm error

x=input("enter a number") if x>10: print("x is greater than 10")

4th Dec 2017, 3:07 AM
APOORV SHUKLA
APOORV SHUKLA - avatar
1 Answer
+ 8
Correct: x = int(input("Enter a number\n") #conversion to int if x > 10: print("x is greater than 10") #Indentation
4th Dec 2017, 3:21 AM
Cool Codin
Cool Codin - avatar