Name
ListItems -- count items of a list (V2.0)
Synopsis
c = ListItems(array)
Function
This function iterates over all items in a list and returns how many items there are in the list. Counting will stop when an element of type Nil is found in the list.

Note that this function only counts items at successive integer indices. It starts at index 0 and counts all items at successive integer indices until a Nil item is encountered. To count all items of a table, use the TableItems() function instead. See TableItems for details.

Inputs
array
table whose items are to be counted
Results
c
counter
Example
Print(ListItems({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}))
This returns 10.

Show TOC