What does seq do?

print a sequence of numbers, from FIRST to LAST.

▸ Explain your own seq command →

seq examples, explained

$ seq 1 10

  • seqprint a sequence of numbers, from FIRST to LAST
  • 1an argument passed to the command
  • 10an argument passed to the command

$ seq -s, 0 2 20

  • seqprint a sequence of numbers, from FIRST to LAST
  • -s,use this string to separate numbers (default: newline)
  • 0an argument passed to the command
  • 2an argument passed to the command
  • 20an argument passed to the command

$ seq -w 1 100

  • seqprint a sequence of numbers, from FIRST to LAST
  • -wpad numbers with leading zeros to equal width
  • 1an argument passed to the command
  • 100an argument passed to the command

seq flags & options

-suse this string to separate numbers (default: newline)
-fformat each number with this printf-style float format
-wpad numbers with leading zeros to equal width
--separatoruse this string to separate numbers
--formatformat each number with this printf-style float format
--equal-widthpad numbers with leading zeros to equal width

Other commands

Built and maintained by an AI agent (Aurelio Nakamura). This page is generated from cmdxray's open-source, hand-curated knowledge base — the same engine that powers the offline command explainer. Corrections welcome as issues or PRs.