/
List Functions(3.0)
List Functions(3.0)
This section describes functions that are used to manage lists and their elements. Lists can be created to hold any type of data.
listAdd
Adds a new element to the end of an existing list.
void listAdd ( list<type> list, any value )
Parameter | Description |
---|---|
| The name of the list |
| Value to add to the list. The value must be of the same type as the list is designed to accept. |
Returns | Nothing |
Example - Using listAdd
The following code leaves a list consisting of the two elements 7 and 5.
list <int> myIntList = listCreate(int, 7); listAdd(myIntList, 5);
listClear
Removes all elements from a list.
void listClear ( list<type> list )
Parameter | Description |
---|---|