Operators
The operators permitted in expression are:
Operators |
||
---|---|---|
Operator |
Description |
Precedence |
- |
Unary minus |
highest |
^ |
Powers and roots |
|
* |
Multiplication |
|
/ |
Division |
|
% |
Percentage |
|
+ |
Addition |
|
- |
Subtraction |
|
= |
Equal to |
|
<> |
Not equal to |
|
< |
Less than |
lowest |
<= |
Less than or equal to |
|
> |
Greater than |
|
>= |
Greater than or equal to |
Operators in expression having the same precedence associate left-to-right.
example:
=((-1 + X^2) * 3 - Y)/2
produces the result 21.5
. ]
The equality, inequality, and relational operators yield 1 for true and 0 for false. An expression with value 0 tests logically false while one with any non-zero value tests true.