6 ms·
It doesn't. isOdd('') => false isOdd(null) => false isOdd(2n) => TypeError: Cannot convert a BigInt value to a number But even if it did, the same line
by eeereerews 6y ago
It doesn't.
isOdd('') => false
isOdd(null) => false
isOdd(2n) => TypeError: Cannot convert a BigInt value to a number
But even if it did, the same line of reasoning leads to the absurd conclusion we should have an addOne function.