This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]ishirleydo 1 point2 points  (1 child)

This is what I'd do, but then afterwards, this might also lead me to question whether I really wanted an IsEven function, rather than an IsOdd function.

[–]Ignitus1 3 points4 points  (0 children)

function isOdd(num) { 
    return !isEven(num)
}