@{ $hoa{ $k } } = [ $val1[ $idx ], $val2[ $idx ] ];
I think you'd either want to remove the @{} notation, or else change your square brackets to parentheses. Your line there is creating a strange data structure there :)
# this @{ $hoa{ $k } } = ( $val1[ $idx ], $val2[ $idx ] ); # or this $hoa{ $k } = [ $val1[ $idx ], $val2[ $idx ] ];
In reply to Re^2: hashes with multiple values per key
by saskaqueer
in thread hashes with multiple values per key
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |