15 min +50 XP
Lesson 22Step 1 of 5

Comparison Operators

Compare values with ==, ===, >, <, and more

What are Comparison Operators?

Comparison operators let you compare two values. They always return either true or false, which makes them perfect for if statements!

All Comparison Operators

===

Strictly equal (same value AND type)

!==

Strictly not equal

>

Greater than

<

Less than

>=

Greater than or equal

<=

Less than or equal