in reply to array problem

A quick perldoc -q shuffle array gives:
How do I shuffle an array randomly?
Use this: # fisher_yates_shuffle( \@array ) : # generate a random permutation of @array in place sub fisher_yates_shuffle { my $array = shift; my $i; for ($i = @$array; --$i; ) { my $j = int rand ($i+1); next if $i == $j; @$array[$i,$j] = @$array[$j,$i]; } } fisher_yates_shuffle( \@array ); # permutes @array in place
Other points to consider: I'm sure I've missed a few things. Sorry to sound overly harsh but I'm trying to be constructive :)

gav^