Below is a list of the operators in ELDARScript. Operators with higher precedence are evaluated before operators with lower precedence (so 1 + 2 x 3
is 7 - the multiplication of 2 and 3 is done before the addition - not 9). Operators with the same precedence are evaluated left to right
Precedence | Operator | Notes |
---|---|---|
1 | . | Expression terminator |
, | List combiner | |
2 | ← | Assignment |
if then [elif then] else end | Conditional | |
3 | ∧ | Min |
∨ | Max | |
4 | > ≥ = ≠ < ≤ | Comparison |
in | Membership | |
5 | … | Range |
6 | + | Addition |
- | Subtraction | |
7 | × | Multiplication |
% | Modulo | |
/ ÷ /+ /- /= | Division | |
8 | [ ] | Subscript |
9 | ( ) | Grouping |