Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript check if a number is even or odd

const isEven = num => num % 2 === 0;

console.log(isEven(2)); 
// Result: True
Source by dev.to #
 
PREVIOUS NEXT
Tagged: #javascript #check #number #odd
ADD COMMENT
Topic
Name
5+9 =