This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
manual:Calculations [2021/10/04 02:58] peternlewis |
manual:Calculations [2021/10/04 02:58] peternlewis |
||
---|---|---|---|
Line 28: | Line 28: | ||
| Comparison Operators (`<, ≤, =, >, ≥, ≠`) | compare for (in)equality and return 0 or 1. | | | Comparison Operators (`<, ≤, =, >, ≥, ≠`) | compare for (in)equality and return 0 or 1. | | ||
| Shift Operators (`≪, ≫`) | shift a number left or right. | | | Shift Operators (`≪, ≫`) | shift a number left or right. | | ||
- | | Arithmetic Multiplication Operators\\ • Multiply (`*`)\\ • Divide (`/`) | Basic mathematical operations. | | + | | Arithmetic Addition Operators \\ • Add (`+`)\\ • Subtract (`-`) | Basic mathematical operations. | |
- | | Arithmetic Additiona Operators\\ • Add (`+`)\\ • Subtract (`-`) | Basic mathematical operations. | | + | | Arithmetic Multiplication Operators \\ • Multiply (`*`)\\ • Divide (`/`) | Basic mathematical operations. | |
| [Modulo](https://en.wikipedia.org/wiki/Modulo_operation) (`i MOD n`) | The remainder of the division of `i` by `n`.\\ Both values (`i`, `n`) will be treated as integer.\\ `n` must not be 0.\\ the sign of the result is the same as the sign of i. | | | [Modulo](https://en.wikipedia.org/wiki/Modulo_operation) (`i MOD n`) | The remainder of the division of `i` by `n`.\\ Both values (`i`, `n`) will be treated as integer.\\ `n` must not be 0.\\ the sign of the result is the same as the sign of i. | | ||
| Integer division (`i DIV n`) (v9.0+)| The integer quotient of the division of `i` by `n`.\\ Both values (`i`, `n`) will be treated as integer.\\ `n` must not be 0.\\ the sign of the result matches the sign of regular division. | | | Integer division (`i DIV n`) (v9.0+)| The integer quotient of the division of `i` by `n`.\\ Both values (`i`, `n`) will be treated as integer.\\ `n` must not be 0.\\ the sign of the result matches the sign of regular division. | |