To refer to an entire array variable (for assignment, parameter, comparison, etc) just use the array variable name.
To refer to an individual element in the array, you need to specify the array variable name and the index value for the element you want.
PUT(coord1('b')); total := coord1('a') + coord1('b') + coord1('c'); PUT(arr3(-2));
You need to be careful with the index value:
Remember, you refer to an element of the array variable, not of the array type.
An example program shows the use of an array to tally the number of times each lower-case letter appears in some text typed by the user.
You can find out some things about an array variable or array type by referring to the attributes of the array.
You can assign one entire array variable to another of the same type
coord1:= coord2;
You can compare one array variable to another of the same type
if (coord1 /= coord2) then PUT("They are different"); end if;
You can use an array variable as an actual parameter to a procedure or function.
The amount of flexibility you have in doing so depends on how the formal parameter was declared in the subprogram:
An example shows the benefit of using unconstrained array types for parameters.