Welcome to the Treehouse Community
Looking to learn something new?
Justin LeeCourses Plus Student 593 Points
If return not 0 turn falsey to true, wouldn't return not 1 make it falsey?
This is from even_odd question under python basic.
def even_odd(num): # If % 2 is 0, the number is even. # Since 0 is falsey, we have to invert it with not. return not num % 2
[MOD: added ```python formatting -cf]
Chris FreemanTreehouse Moderator 67,989 Points
Correct. The 1 means it was an odd number. Since 1 is truthy,
not 1 is
return not 1 will return a
False if an odd number is submitted.