seq for generators

Output sequences of numbers.

Signature

> seq {flags} ...rest

Parameters

  • ...rest: sequence values

Input/output types:

inputoutput
nothinglist<number>

Examples

sequence 1 to 10

> seq 1 10
╭───┬────╮
 0   1 
 1   2 
 2   3 
 3   4 
 4   5 
 5   6 
 6   7 
 7   8 
 8   9 
 9  10 
╰───┴────╯

sequence 1.0 to 2.0 by 0.1s

> seq 1.0 0.1 2.0
╭────┬──────╮
  0  1.00 
  1  1.10 
  2  1.20 
  3  1.30 
  4  1.40 
  5  1.50 
  6  1.60 
  7  1.70 
  8  1.80 
  9  1.90 
 10  2.00 
╰────┴──────╯

sequence 1 to 5, then convert to a string with a pipe separator

> seq 1 5 | str join '|'

Subcommands:

nametypeusage
seq charBuiltinPrint a sequence of ASCII characters.
seq dateBuiltinPrint sequences of dates.