sub popmany { # See previous foil for use
-
my $aref; # A local scalar to hold pointer to array
-
my @retlist = (); # An array to hold returned list
-
foreach $aref ( @_ ) { # $aref loops over arguments
-
push(@retlist, pop(@$aref) ); # @$aref is global array pointed to in argument
-
} # Now we have popped off last element in each input array
-
return @retlist; # @retlist has last element of each array passed
|