Operator Associativity

If two operators in an expression have the same precedence level, they are evaluated from left to right or right to left depending on their associativity.

For example, addition’s associativity is Left to Right, so the expression 2+3+4 is evaluated as (2+3)+4. In contrast, the assign operator’s associativity is Right to Left; so the expression x=y=z is evaluated as x=(y=z).

See About Operators.