// vanilla
function isEven(num) {
return num % 2 == 0;
}
function isOdd(num) {
return Math.abs(num % 2) == 1;
}
// ES6
const isEven = num => ((num % 2) == 0);
//bitwise AND operator
const isOdd = function(num) { return num & 1; };
const isEven = function(num) { return !( num & 1 ); };