in reply to Re: Re: randomly choosing elements from an array
in thread randomly choosing elements from an array
my @result; push @result, splice @list, rand @list, 1 while @result < $n;
-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.
|
|---|