in reply to Re: help in understanding the standard array shuffle
in thread help in understanding the standard array shuffle
Because your randomizing function has no memory to guarantee this consistency, you'll be very surprised by the behavior. Older qsort functions would in fact dump core or lose data on this kind of pseudo-shuffle. Modern perls use an internal sort function that at least doesn't lose the data, but it's really not the way to do a shuffle nicely. See the FAQ solution instead, quoted at the head of this thread.
-- Randal L. Schwartz, Perl hacker
|
|---|