Created
December 16, 2017 21:41
-
-
Save zznop/3982a5e11eb7b6794825623e3d6df305 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int is_odd(int number) | |
{ | |
return number == 0 ? 0 : is_even(abs(number) - 1); | |
} | |
int is_even(int number) | |
{ | |
return number == 0 ? 1 : is_odd(abs(number) - 1); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment