+ 1
Question
>>> num=7 >>> if num==5: print(ânumber is 5â) else: Syntax error: invalid syntax
2 Answers
+ 3
Is there a line after this line?
else:
If not, remove the else or:
else:
pass
+ 1
Just after else it gives a syntax error
>>> num=7 >>> if num==5: print(ânumber is 5â) else: Syntax error: invalid syntax