4.2.Relational #

Relational Operator

The equality and relational operators determine if one operand is greater than, less than, equal to, or not equal to another operand. The majority of these operators will probably look familiar to you as well. Keep in mind that you must use “==”, not “=”, when testing if two primitive values are equal.

Operator Description
== equal to
!= not equal to
> greater than
< greater than or equal to
>= less than
<= less than or equal to


Suggest Edit