JavaScript has two types of operator:
We have met some before the others should obvious.
Table of Operators
Logical Operators:
== | equal to |
!= | not equal to |
Operator | Description |
> | greater than |
>= | greater than or |
equal to | |
< | less than |
<= | less than or |
equal to | |
&& | logical AND |
|| | logical OR |
Operators on Variables:
= | variable assignment |
+,-,/,*,% | Common arithmetic |
+ | String Concatenate |
+= | add then assign |
-= | subtract then assign |
*= | multiply then assign |
/= | divide then assign |
%= | modulus division then assign |
++ | autoincrement |
- | autodecrement |
! | logical not |