Summary of Operators
The following quick reference summarizes the operators supported by the Java programming language.
Simple Assignment Operator
= simple assignment operator
Arithmetic Operators
+ additive operator (also used for String concatenation)
- subtraction operator
* multiplication operator
/ division operator
% remainder operator
Unary Operators
+ Unary plus operator; indicates positive value
(numbers are positive without this, however)
- Unary minus operator; negates an expression
++ Increment operator; increments a value by 1
-- Decrement operator; decrements a value by 1
! Logical complement operator; inverts the value of a boolean
Equality and Relational Operators
== equal to
!= not equal to
> greater than
>= greater than or equal to
< less than
<= less than or equal to
Conditional Operators
&& Conditional-AND
|| Conditional-OR
?: Ternary (shorthand for if-then-else statement)
Type Comparison Operator
instanceof compares an object to a specified type
Bitwise and Bit Shift Operators
~ unary bitwise complement
<< signed left shift
>> signed right shift
>>> unsigned right shift
& bitwise AND
^ bitwise exclusive OR
| bitwise inclusive OR
http://java.sun.com/javase/reference/index.jsp