in reply to UPDATED: Forking On Foreach Keys In Hash, Passing Hash To Sub, And Speed/Efficiency Recommendations
You need to dereference the hashref in your subroutine.
$hashref{$key} = $npanxxcnt;
needs to be:
$$hashref{$key} = $npanxxcnt;
or
${$hashref}{$key} = $npanxxnct;
Also, your subroutine returns values but they are not stored anywhere in the calling program.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Forking On Foreach Keys In Hash, Passing Hash To Sub, And Speed/Efficiency Recommendations
by Anonymous Monk on Aug 09, 2014 at 00:20 UTC |