@Count (JavaScript)

Returns the number of entries in a list.

Defined in

@Functions (JavaScript)

Syntax

@Count(list:any) : int
Parameter Description
list The list to be checked.
Return value Description
int Number of entries in the list.

Usage

A list is an array.

Examples

This example iterates through a list.
function p(stuff) {
	print("<<<" + stuff + ">>>");
}

var citiesArray = new Array("Paris", "Berlin", "London", "Moscow");

for(var i = 0; i < @Count(citiesArray); i++) {
	p(citiesArray[i]);
}