Created
December 25, 2014 02:30
-
-
Save IsraelBuitronD/3e30478f7c8b66278556 to your computer and use it in GitHub Desktop.
Check if integer is odd or even
This file contains hidden or 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
| if((x&1) == 0) { | |
| // x is even | |
| } else { | |
| // x is odd | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment