CodePeek
Practice / ValuesBack to CodePeek

JavaScript Equality: Equal-ish

Puzzle 3 of 15 · Equality

Compare loose equality (==) and strict equality (===) between a number and a boolean. Predict the result of each comparison. Choose an output below, then check the explanation. No signup needed. Browse puzzles by topic →

Values / EqualityJavaScript
console.log(0 == false);
console.log(0 === false);

Predict the console output. Each line is a separate log.

What’s the output?

Choose the output

Starter puzzles 15