Home/Support/Support Forum/Using sort command I want to arrange each line, which is having two numbers, in ascending order.
Welcome to Digi Forum, where you can ask questions and receive answers from other members of the community.

Using sort command I want to arrange each line, which is having two numbers, in ascending order.

0 votes
Using sort command I want to arrange each line, which is having two numbers, in ascending order.

For example:

Contig1, 23, 35

Contig2, 52, 15

Contig3, 43, 20

Contig4, 58, 88

Contig5, 38, 61

The result should be

Contig1, 23, 35

Contig2, 15, 52

Contig3, 20, 43

Contig4, 58, 88

Contig5, 38, 61

I have tried :%sort! -n but its not working in the way which I want.
asked Sep 30, 2014 in Other/Legacy by kashiff007 New to the Community (0 points)

Please log in or register to answer this question.

1 Answer

0 votes
What product are you using?
answered Sep 30, 2014 by MargaretK Veteran of the Digi Community (545 points)
I am using Vim editor
...