Linux command--seq

Source: Internet
Author: User

Seq Command description

Used to generate all integers from one number to another.

Grammar
seq [Options] ... Mantissa seq [Options] ... First number mantissa seq [Options] ... First number increment Mantissa
Options
-F uses the printf-style floating-point format-s to separate numbers using the specified string (by default: \ n)-W adds 0 to the column before the columns are the same width
Instance-f Specifies the format
Seq-f "%5g" 1 5

650) this.width=650; "src=" Https://i.imgur.com/yqrc85P.gif "style=" Margin-top:0px;margin-right:0px;margin-bottom : 0px;margin-left:0px;padding-top:0px;padding-right:0px;padding-bottom:0px;padding-left:0px;border-top-width:0 px;border-right-width:0px;border-bottom-width:0px;border-left-width:0px; "alt=" Yqrc85P.gif "/>

Description%The number of digits after the specified number, the default is%g,%5gRepresents a 5-bit, then the number of digits is less than the space

Seq-f "%05g" 1 5seq-f "str%05g" 1 5

650) this.width=650; "src=" Https://i.imgur.com/jQO2JpB.gif "style=" Margin-top:0px;margin-right:0px;margin-bottom : 0px;margin-left:0px;padding-top:0px;padding-right:0px;padding-bottom:0px;padding-left:0px;border-top-width:0 px;border-right-width:0px;border-bottom-width:0px;border-left-width:0px; "alt=" JQO2JpB.gif "/>

Use0Instead of a space output,%Front Custom string

-W Specifies the same width as the output number
Seq-w 5 10

650) this.width=650; "src=" Https://i.imgur.com/WG7sobC.gif "style=" Margin-top:0px;margin-right:0px;margin-bottom : 0px;margin-left:0px;padding-top:0px;padding-right:0px;padding-bottom:0px;padding-left:0px;border-top-width:0 px;border-right-width:0px;border-bottom-width:0px;border-left-width:0px, "alt=" WG7sobC.gif "/> Note: cannot and-fTogether, the output is the same width

-S Specify delimiter (default is carriage return)
Seq-s ""-F "str%05g" 1 5seq-s "' Echo-e" \ T "'" 1 5

650) this.width=650; "src=" Https://i.imgur.com/2aFp7hI.gif "style=" Margin-top:0px;margin-right:0px;margin-bottom : 0px;margin-left:0px;padding-top:0px;padding-right:0px;padding-bottom:0px;padding-left:0px;border-top-width:0 px;border-right-width:0px;border-bottom-width:0px;border-left-width:0px; "alt=" 2aFp7hI.gif "/>


This article is from the "wind and Rain Forest" blog, please make sure to keep this source http://fengyushanlin.blog.51cto.com/12092006/1978839

Linux command--seq

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.