Let's investigate

In value comparison checks, we have so far used only the 3 equal signs: ===. What if we just tried with two? Guess what each console statement prints.

Did that last one take you by surprise? It sure did for me 😳. This all may look like yet more of JavaScript’s weird and wonderful oddities, but I can assure you there is more reason than madness! Let's try another.

Do you think the console.log statement will run? Why / why not? 🤔. What exactly is happening here?

Let’s turn our attention to operators.

Do you think there is a difference between these 2 addition operations?

What will the result below be? Why do you think we ended up with each value? What had to change?

Compare these 2 syntaxes for conditional logic - you might be surprised by the outcome 😂.

Besides the result of each, what elements /patterns do both have?

Okay, time to learn

We have played around a bit in the console. Let’s improve our mental model of operations and flow in JavaScript.