What to write in if and elif to run the program? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

What to write in if and elif to run the program?

def greater_less_equal_5(answer): if : return 1 elif : return -1 else : return 0 print greater_less_equal_5(4) print greater_less_equal_5(5) print greater_less_equal_5(6) if anyone know how to fix the problem then plz help...

17th Aug 2016, 6:51 AM
Isak Sayyed
Isak Sayyed - avatar
1 Answer
0
if answer>5: return "grater than 5" elif answer<5: return "less than 5" else: return "equal 5"
17th Aug 2016, 8:42 AM
nima sadeghpour