sub shuffle { my @in = @_; my @out; push @out, splice(@in, rand @in, 1) while @in; @out; }