LIST Function
Creates a list array.
Usage
result = LIST(expr1 , ... exprn)
Input Parameters
expriOne or more expressions or variables.
Returned Value
result—A variable of type LIST.
Keywords
None.
Discussion
A list is an array of expressions or variables. Each element in a list can have a unique data type and value. The elements in a list can be accessed with subscripts, in much the same way that elements of an array are accessed.
The elements of a list can be any of the basic PV‑WAVE data types, or other structures or arrays of structures, and other lists or associative arrays. Lists can also be used as structure fields.
Example
This example creates a simple list with four elements: a byte value, a floating-point value, a string, and a structure. Both INFO and PRINT are used to show the contents and structure of the list.
; Create the list.
lst = LIST(1B, 2.2, '3.3', {,a:1, b:lindgen(2)})
; Display information about the list.
INFO, lst, /Full
; PV-WAVE prints the following:
; LST LIST = List(4)
;   BYTE = 1
;   FLOAT = 2.20000
;   STRING = '3.3'
;   STRUCT = ** Structure $1, 2 tags, 24 length:
;     A INT 1
;     B LONG Array(2)
PRINT, lst
; Print the value of the list.
; { 1 2.20000 3.3{ 1 0 1}}
See Also