Return the associativity of the operator `char`. https://en.wikipedia.org/wiki/Operator_associativity
(char: str)
| 35 | |
| 36 | |
| 37 | def associativity(char: str) -> Literal["LR", "RL"]: |
| 38 | """ |
| 39 | Return the associativity of the operator `char`. |
| 40 | https://en.wikipedia.org/wiki/Operator_associativity |
| 41 | """ |
| 42 | return ASSOCIATIVITIES[char] |
| 43 | |
| 44 | |
| 45 | def infix_to_postfix(expression_str: str) -> str: |