Skip to main content

List.Times

Generates a list of time values given an initial value, count, and incremental duration value.

Syntax

List.Times(
start as time,
count as number,
step as duration
) as list

Remarks

Returns a list of time values of size count, starting at start. The given increment, step, is a duration value that is added to every value.

Examples

Example #1

Create a list of 4 values starting from noon (#time(12, 0, 0)) incrementing by one hour (#duration(0, 1, 0, 0)).

List.Times(#time(12, 0, 0), 4, #duration(0, 1, 0, 0))

Result:

{
#time(12, 0, 0),
#time(13, 0, 0),
#time(14, 0, 0),
#time(15, 0, 0)
}

Category

List.Generators