Kevin Reid wrote:
> 
> sub rotate { unshift @_, splice @_, shift @_; return @_ }


$ perl -le'
sub rotate { unshift @_, splice @_, shift @_; return @_ }
@x = qw/a b c d e f/;
print "@x";
print "@{[rotate @x]}"; 
'
a b c d e f
b c d e f


Doesn't shift() do pretty much the same thing?  :-)


John
-- 
use Perl;
program
fulfillment

Reply via email to