<iota> ( n -- iota )
Factor handbook » The language » Collections » Sequence operations » Counted loops


Vocabulary
sequences

Inputs
nan integer


Outputs
iotaan iota


Word description
Creates an immutable virtual sequence containing the integers from 0 to n-1.

Examples
USING: math sequences prettyprint ; 3 <iota> [ sq ] map .
{ 0 1 4 }


Definition