+ 2

hello pls im looking for a way to solve gotham city in python and i need help

criminals = int(input()) if (criminals < 5): print("'I got this!'") elif (criminals >= 5 and <= 10): print("'Help me Batman'") else: print("'Good Luck out there!'") I cannot find why i always get syntax error at elif

18th Jul 2020, 3:56 PM
Timi Toba
Timi Toba - avatar
2 Respostas
+ 14
In second if statement must be like elif (criminals >= 5 and criminals <= 10): # <= check to what after and, so need criminals var name another note: Doesn't need (') after (") in print because it will make test case failed
18th Jul 2020, 4:08 PM
᮴Ridwan_
᮴Ridwan_ - avatar
+ 1
thanks
22nd Jul 2020, 10:11 PM
Timi Toba
Timi Toba - avatar