How do you sort numerically in Linux?

How do you sort numerically in Linux?
Answer
To sort by
number pass the -n option to sort. This will sort from lowest number to highest number and write the result to standard output. Suppose a file exists with a list of items of clothing that has a number at the start of the line and needs to be sorted numerically. The file is saved as clothes.
 

Tìm kiếm

Back
Top