Arithmetic operators

Java supports using the following classical arithmetic operators

  • Multiplication *
  • Division /
  • Modulus % 
  • Addition +
  • Subtraction -

Assignment operators

These operators are usually used to assign Mathematical operations results to variables .The most-used assignment operator is the equal operator "=", which simply assigns operations' result to variables.

Sometimes, You'll encounter Compound Assignment operators which always have the equal sign on the right side beside other operators +=, -=, *=, /=, %=, &=, ^=, !=, <<=,>>=, >>>=

This way of writing operators behaves as a shortcut that uses the previous value of the statement's variable as an operand in the whole operation.