JavaScript Converting a number to a boolean


Example

Boolean(0) === false

Boolean(0) will convert the number 0 into a boolean false.

A shorter, but less clear, form:

!!0 === false