Unsort 1.0

Unsort project is the natural opposite to standard 'sort', it takes lines and shuffles them.

  Add it to your Download Basket!

 Add it to your Watch List!

0/5

Rate it!
send us
an update
LICENSE TYPE:
Public Domain 
USER RATING:
5.0/5 1
DEVELOPED BY:
gatopeich
HOMEPAGE:
gatopeichs.pbwiki.com
CATEGORY:
ROOT \ Utilities
Unsort project is the natural opposite to standard 'sort', it takes lines and shuffles them. I wonder how it is not part of every standard UNIX system. How the hell did they test 'sort'?

$ echo -e "1n2n3n4n5n7"|unsort
stderr> Using seed: 542941369
7
4
1
5
2
3
stderr> Jumps: 4 left, 4 right, balance: 1.000000

This 'unsort' implementation goes as follows:

reads lines from standard input
assigns them random, unique indexes
sorts lines by their random index
when input finishes, lines are dumped as sorted.

The only limitation I have found so far is about sheer size. The whole file is kept in memory while being sorted.

Compile and Install:

Simple build & install instructions can be found at the beggining of the file.

Last updated on June 7th, 2007

#shuffle lines #unsort files #scuffle files #Unsort #shuffle #scuffle #shamble

Add your review!

SUBMIT