Comparision Operators
When writing conditional statements, we need to use different types of operator to compare values.
List of some handy comparision operators:
Less than
<
Greater than:
>
Less than or equal to:
<=
Greater than or equal to:
>=
is equal to:
==
is not equal to:
!=
Comparision operators compare the value on the left with the value on the right.
Example:
Example:
Last updated