Level |
A |
Operators |
Description |
15 |
L |
. [] (args) ++ -- |
object member, array access, function call, post-increment/decrement |
14 |
R |
++ -- + - ~ ! |
pre-increment/decrement, unary +, unary negate, bitwise NOT, logical NOT |
13 |
R |
new (type) |
creation, cast |
12 |
L |
* / % |
multiplication, division, modulus remainder |
11 |
L |
+ - |
(binary) addition/string concatenation, subtraction |
10 |
L |
<< >> >>> |
arithmetic left shift, arithmetic right shift (sign extension), logical right shift (zero fill) |
9 |
L |
< <= > >= instanceof |
relational: less-than, less-than or equals, greater-than, greater-than or equals, compare-type |
8 |
L |
== != |
relational: equals, not equals |
7 |
L |
& |
bitwise AND |
6 |
L |
^ |
bitwise XOR (exclusive or) |
5 |
L |
| |
bitwise OR (inclusive or) |
4 |
L |
&& |
relational AND |
3 |
L |
|| |
relational OR |
2 |
R |
e ? t : f |
conditional (if e then t else f) |
1 |
R |
= *= /= %= += -= «= etc. |
assignment |