Character arrays
An element of a array character variable is a character string, for example,
T is an array character variable with 3 elements:
T[1] = 'This is line one' T[2] = 'This is line two' T[3] = 'This is line three'
Array character variables can be defined with the
READ
command by entering more than one line number to read. For example:
READ\TEXT FILE.DAT/[1:5] T
creates array character variable T with
5 elements. Array character variables can also be defined with a
character assignment, as above.
To specify the character elements of an array element of a array character
variable, use another set of brackets. For example, if
T[3]='abcdefghijkl' then
T[3][1:10:2] specifies characters
1, 3, 5, 7, 9 of array element 3 of the array
character variable T, which is
'acegi'. There is no maximum number of array elements for a
character variable. There is no maximum character length for an
array element.