Associativity Rule
For operators at the same precedence level, the associativity rule dictates the order of evaluation:
Unary operators: right to left
Binary operators: left to right
Example: 3 * (12 - 7) % 4 - (16 / (2 + 2 * 3 - 1))
Previous slide
Next slide
Back to first slide
View graphic version