Skip to content

Instantly share code, notes, and snippets.

@ianpgall
Created March 11, 2014 17:32
Show Gist options
  • Select an option

  • Save ianpgall/9490801 to your computer and use it in GitHub Desktop.

Select an option

Save ianpgall/9490801 to your computer and use it in GitHub Desktop.
JavaScript function that determines whether a number is odd
function isOdd(num) {
return !!(num & 1);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment