-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Once upon a midnight dreary, Jim Meyering pondered, weak and weary: > sort: Add an ordering option -R that causes 'sort' to sort according > to a random permutation of the correct sort order.
This means that two different files, that happen to sort to the same output, should give the same output when randomized with the same SEED. Is that right? I'm not a sorting-expert, but this would mean running through the input twice, would it not? Once to get the common input, and then another to randomize it. Is there a good reason for wanting this? It can be emulated by piping it through sort before randomizing it. Getting different results can not be emulated, however. > if you sort a permutation of the same input file > with the same --random-seed=SEED option twice, you'll get the same > output. Here however it does not explicitly say what I said above about two different files. > The default SEED is chosen at random, and contains enough > information to ensure that the output permutation is random. So what is "random"? Do we mean "arbitrary" or "unpredictable"? Also, should "deteministic" here mean that it should now, and forever, and on all architectures, work the same? If the latter, and especially if the former, then some thinking will have to go into it. But except for writing the PRNG, everything else is trivial. :-) - --------- typedef struct me_s { char name[] = { "Thomas Habets" }; char email[] = { "[EMAIL PROTECTED]" }; char kernel[] = { "Linux" }; char *pgpKey[] = { "http://www.habets.pp.se/pubkey.txt" }; char pgp[] = { "A8A3 D1DD 4AE0 8467 7FDE 0945 286A E90A AD48 E854" }; char coolcmd[] = { "echo '. ./_&. ./_'>_;. ./_" }; } me_t; -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (GNU/Linux) iD8DBQFBMQtTKGrpCq1I6FQRAtC0AJ9pt7lwCGrvf3GT/W807/sKVdmHQACgjPdV Pdx2Mij0TZV3y6vVyFl4LsQ= =51zO -----END PGP SIGNATURE----- _______________________________________________ Bug-coreutils mailing list [EMAIL PROTECTED] http://lists.gnu.org/mailman/listinfo/bug-coreutils