in reply to hash of arrays to a subrutine?
Sub( \%hash ); sub Sub { # example avoiding copying data around in bulk. my $href = shift; for my $aref ( keys %$href ) { # loop the hash for ( my $idx=0; $idx <= $#$aref; $idx++ ) { # loop array Process( $aref -> [$idx] ); } } } sub Process { my $scalar = shift; # whatever with the array element }
|
|---|