2

Maybe am missing something but how do i sort in a descending order a list with this naming

B7
B40
B41
B42
B8
B43
B20
B45
B53
B47
B48
B5
B6

sort -n does not sort the way i would like

B5
B6
B7

and so on

0

1 Answer 1

3

Try this:

sort -k1.2n

This sorts by (the data starting at) the second char (2) of the first column (1), assuming numerical data (n).

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .