SEQ(1) | General Commands Manual | SEQ(1) |
seq
—
seq |
[-w ] [-f
format] [-s
string] [-t
string] [first
[incr]] last |
seq
utility prints a sequence of numbers, one per
line (default), from first (default 1), to near
last as possible, in increments of
incr (default 1). When first is
larger than last, the default incr
is -1.
All numbers are interpreted as floating point.
Normally integer values are printed as decimal integers.
The seq
utility accepts the following
options:
-f
formatA
, a
,
E
, e
,
F
, f
,
G
, g
, and
%
conversion characters are valid, along with any
optional flags and an optional numeric mimimum field width or precision.
The format can contain character escape sequences in
backslash notation as defined in ANSI X3.159-1989
(“ANSI C89”). The default is
%g
.-s
string\n
.-t
string\n
.-w
-f
option. If
any sequence numbers will be printed in exponential notation, the default
conversion is changed to %e
.seq
utility exits 0 on success,
and >0 if an error occurs.
# seq 1 3 1 2 3 # seq 3 1 3 2 1 # seq -w 0 .05 .1 0.00 0.05 0.10
seq
command first appeared in Version 8
AT&T UNIX. A seq
command
appeared in NetBSD 3.0. This command was based on the
command of the same name in Plan 9 from Bell Labs and the GNU core utilities.
The GNU seq
command first appeared in the 1.13 shell
utilities release.
-w
option does not handle the transition from pure
floating point to exponent representation very well. The
seq
command is not bug for bug compatible with other
implementations.
December 17, 2018 | NetBSD 9.4 |