Operations

Priority Operator Description Associativity
15 ()
()
[]
.
++
--
parenthesis
function call
array access
member access
post-increment
post-decrement
left to right
14 ++
--
+
-
!
~
pre-increment
pre-decrement
unary plus
unary minus
logical NOT
bitwise NOT
right to left
13 ** power left to right
12 *
/
%
%%
multiplication
division
remainder
modulo
11 +
-
addition
substraction
10 <<
>>
>>>
rol
ror
bitwise left shift
bitwise right shift
bitwise zero-fill right shift
bitwise left rotation
bitwise right rotation
9 <
<=
>
>=
instanceof
relational <
relational ≤
relational >
relational ≥
instanceof
8 ==
===
!=
!==
relational =
relational strict =
relational ≠
relational strict ≠
7 & bitwise AND
6 ^ bitwise XOR
5 | bitwise OR
4 && logical AND
3 || logical OR
2 ?: ternary conditional left to right
1   =  <<=  >>= >>>=
 !=   ~=   +=   -=
**=   *=   /=   %=
%%=   &=   ^=   |=
&&=  ||=
assignments

Last update: March 28, 2021