pTAL Reference Manual (H06.03+)
HP pTAL Reference Manual—523746-005
8-1
8 Arrays
An array is a one-dimensional set of elements of the same data type. Each array is
stored as a collective group of elements. You use arrays to store constants, especially
character strings. After you declare an array, you can use its identifier to access the
array elements individually or as a group.
You can declare:
•
Arrays
•
Read-only arrays
•
Address arrays
The declaration includes initializing the array as well as allocating storage for the array.
In addition the declaration determines:
•
The kind of values the array can represent
•
The operations you can perform on the array
•
The byte or word addressing mode of the array
This section defines the syntax for declaring:
•
Arrays
•
Read-only arrays
•
Address arrays
Section 9, Structures, describes the syntax for declaring arrays within structures and
how to declare structures that simulate arrays of arrays, or arrays of structures
(including multidimensional arrays).
Topics:
•
Declaring Arrays on page 8-2
•
Declaring Read-Only Arrays on page 8-6
•
Using Constant Lists in Array Declarations on page 8-8










