more useful options | |
PerlMonks |
Re: How to improve my code? main concern:array as hash elementby wfsp (Abbot) |
on Nov 23, 2011 at 15:56 UTC ( [id://939690]=note: print w/replies, xml ) | Need Help?? |
You probably need
Hash values can only be scalars. An array reference is a scalar so we can use that. In your while loop you will first need to test if it is an array ref and, if so, dereference it. Something like (not tested) update: fixed typo
In Section
Seekers of Perl Wisdom
|
|