Operator Precedence

The following table shows the order of precedence for Java operators, from highest to lowest.

  1. () [] . (Highest)
  2. ++ - - ~ !
  3. * / %
  4. + -
  5. >> >>> <<
  6. > >= < <=
  7. == !=
  8. &
  9. ^
  10. |
  11. &&
  12. ||
  13. ?:
  14. = op= (Lowest)
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.