python - What do these mean in print? -
def greater_less_equal_5(answer): if answer > 5: return 1 elif answer < 5: return -1 else: return 0 print greater_less_equal_5(4) print greater_less_equal_5(5) print greater_less_equal_5(6) what these number: 4,5,6 mean , in ending of print?
they arguments/parameters being passed function greater_less_equal_5 value of answer used inside body of function. example, greater_less_equal_5(4) runs code:
if 4 > 5: return 1 elif 4 < 5: return -1 else: return 0 this has nothing print.
Comments
Post a Comment