0

if 10 > 5: print("10 greater than 5") print("Program ended")

i type this and it gives me a syntax error

31st Aug 2020, 12:51 PM
UIRas Gaming
UIRas Gaming - avatar
2 Respostas
+ 2
Just use semicolon after print statement otherwise use 2 .by using tab after inside if block. #1. if 10 > 5: print("10 greater than 5"); print("Program ended") #i type this and it gives me a syntax error #2. if 10>5: print("10 greater than 5"); print("Program ended")
31st Aug 2020, 12:56 PM
Sâñtôsh
Sâñtôsh - avatar
+ 2
Check your python version else it is indentation error.
31st Aug 2020, 3:12 PM
HBhZ_C
HBhZ_C - avatar