my $limit = 0; for $selection ( sort { rand() <=> 0.5 } @array ) { print "$selection\n"; ( ++$limit < 10 ) or last; }