Operator Precedence and Associativity in Programming Languages

OperatorDescriptionAssociativity
( ) [ ] -> .Left to Right
! ~ ++ — + – * &Right to Left
* / %Right to Left
< <= > >= == !=Left to Right
& ^ ||Left to Right
&& || ?:Right to Left
= += -= *= /= %= &= ^= |= <<= >>=Right to Left
,Left to Right


Krantesh Singh

Web Developer & Digital Marketer