cycle(offset,choices)¶
Definition¶
Object cycle(Number offset, Object ... choices)
Description¶
Returns the nth object from choices where n is the offset + 1. If the offset is greater than or equal to the number of choices, n is calculated as (offset % number of choices) + 1.
Parameter Definition¶
Name | Type | Description |
---|---|---|
offset | Number | index into choices |
choices | Object... |