Hello there. I realize this may be just a learning exercise, but the mention of a 'proper' shuffle came up above...
A shuffle is a random list permutation, of which there are n! possibilities. A 'proper' shuffle would emphasize the quality of the random source. PRNG needs at least log2(n!) bits of internal state to be able to generate all possible permutations. List::Util shuffle is likely using drand48.
$ perl -MList::Util=sum -e 'print 1/log(2) * sum map log, 1..17;' 48.337603311133 $ perl -MList::Util=sum -e 'print 1/log(2) * sum map log, 1..1000;' 8529.39800420478
As you can see, 48 bits is not enough to properly shuffle a list of 17 elements. For one thousand element shuffle, more than a kilobyte of randomness is required.
In reply to Re: Shuffling CODONS
by Anonymous Monk
in thread Shuffling CODONS
by WouterVG
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |