Array Expressions

Array expressions can be used only in assignment statements. The result of the evaluation of an array expression is an array. Operations on arrays are performed element by element in row-major order. All arrays referred to in an array expression must have identical dimensions and bounds. Arithmetic operators excluding ** (exponentiation) can be used for array cross-sections.

Array expressions can be used with these operators:

Operator Operation
prefix + Plus
prefix - Minus
+ Addition
- Subtraction
* Multiplication
/ Division
= Equal
^= Not Equal
> Greater than
< Less than
>= Greater than or equal to
<= Less than or equal to
& and
| inclusive or
^ not (complement)
|| or !! Concatenate

Array expressions can be used with these built-ins.

ABS HBOUND RIGHT
ALL LEFT ROUND
ANY LBOUND STRING
BOOL LOWERCASE SUBSTR
CENTERLEFT MIN SUM
CENTERRIGHT MAX TRANSLATE
DIMENSION PROD TRIM
FIXED REVERSE UPPERCASE

Array expressions may include any of the following:

The operation and data conversion rules are the same as for element expressions.