in reply to
Re^2: Array Shuffle
in thread
Array Shuffle
Here's another mechanism for you:
Make a copy of your array
shuffle it (using
List::Util::shuffle
)
do an element-wise comparison of your two arrays and if you find a match swap that element with an adjacent element
goto 3 until you swap no more
duff
Comment on
Re^3: Array Shuffle
In Section
Seekers of Perl Wisdom