rightassociative
Right-associative describes a property of binary operators in formal grammars, programming languages, and mathematics where an expression with multiple occurrences of the operator groups to the right. Specifically, a op b op c is interpreted as a op (b op c) rather than (a op b) op c. This contrasts with left-associative, where grouping is to the left.
Exponentiation is a classic right-associative operator in both mathematics and many programming languages. For example, 2^3^2
Assignments are often right-associative: in languages like C, C++, Java, JavaScript, and Python, a = b = c
In parsing, associativity affects the structure of the parse tree and the order of evaluation, but parentheses
Right associativity is one of several conventions used to define how expressions are evaluated.