DEV Community

Calvin
Calvin

Posted on

Reading Snippets [6]

Non-boolean values are converted to "Truthy" and "Falsy" when placed in comparison operators.

True, all numbers except 0, non empty strings, and everything else may be considered truthy.

False, empty strings, 0 or NAN, and null or undefined may be considered as falsey.

Top comments (0)