Build an array out of a range of numbers or using our range syntax: {start}..{end} or using the from and to arguments
arrayRange(from, to)
returns numeric
Name | Type | Required | Default | Description |
---|---|---|---|---|
from | numeric | Yes | 1 | The initial index, defaults to 1 or you can use the {start}..{end} notation. |
to | numeric | Yes | The last index item, or defaults to the from value. |
arr = arrayRange( "2..5" );
writeOutput('This array has ' & arrayLen(arr) & ' elements.');
arr = arrayRange( 5, 10 );
writeOutput('This array has ' & arrayLen(arr) & ' elements.');