Come for the quick hacks, stay for the epiphanies. | |
PerlMonks |
Re: Re: Re: help in understanding the standard array shuffleby arhuman (Vicar) |
on Feb 14, 2001 at 19:21 UTC ( [id://58355]=note: print w/replies, xml ) | Need Help?? |
It would seem this shuffle guarantees that no element remains in it's current position. This seems less than random. My tests show that SOME elements stay in place ! Did I miss something ? Note: I suspect however that the distribution is not perfect(the items "don't move too far from their position" so i suspect the "distribution" to be biased)... Anyway it's ok for me the way it is, just have to remember it's not a true 'statistical random' change...
In Section
Seekers of Perl Wisdom
|
|