﻿# Operators

The following table lists all of the built-in operators, according to the order of precedence.

| **Operator** | **Precedence**<br>**1=highest** | **Description** |
|------|------|------|
| ^ | 1 | Raise to power, e.g. 5^3 is 5 to the 3rd power or 125 |
| \*\* | 1 | Equivalent to ^ |
| \+ | 2 | Unary plus |
| \- | 2 | Unary minus |
| \* | 3 | Multiplication |
| / | 3 | Division |
| \+ | 4 | Addition or string concatenation |
| \#+ | 4 | Explicit addition; see [Explicit Plus Operators](explicitplusoperators.md) |
| \$+ | 4 | Explicit concatenation; see [Explicit Plus Operators](explicitplusoperators.md) |
| \- | 4 | Subtraction |
| = | 5 | Relational equals, e.g. IF A = B OR C = D THEN ... |
| < | 5 | Relational less than; string or numeric |
| <= | 5 | Relational less than or equals; string or numeric |
| \> | 5 | Relational greater than; string or numeric |
| \>= | 5 | Relational greater than or equals; string or numeric |
| <> | 5 | Relational not equal; string or numeric |
| \# | 5 | Relational not equal; same as <> |
| NOT | 6 | Logical NOT, e.g. IF NOT (A OR B) THEN ... |
| AND | 7 | Logical AND |
| OR | 7 | Logical OR |
| XOR | 7 | Logical XOR; exclusive OR |
| EQV | 7 | Logical equivalence; exclusive NOR |
| MIN | 7 | Minimum (of two operands), e.g. A = B MIN C + D |
| MAX | 7 | Maximum (of two operands), e.g. A = B + C MAX D + E |
| MOD | 7 | Modulo, e.g. A = 37 MOD 8 (remainder of 37 / 8) |
| USING | 8 | Formatting, e.g. A USING "###.##" |




**Subtopics**

- [Implicit String Conversion](implicit-string-conversion.md)

- [USING Mask](using_mask.md)

- [Unary Operators](unaryoperators.md)

- [Overloaded Plus Operator](overloadedplusoperator.md)

- [Explicit Plus Operators](explicitplusoperators.md)

- [Explicit Comparison Operators](explicitcomparisonoperators.md)

- [Binary Arithmetic and Logical Operators](binaryarithlogical.md)

- [Boolean Bitwise Arithmetic](booleanbitwisearithmetic.md)

- [Logical vs. Arithmetic Operators](logicalvsarithoperators.md)

- [Shortcut Operators](shortcutoperators.md)

- [Substring Operator](substringoperator.md)

- [Copy, Add, Subtract Collections](copyaddsubtractcollections.md)