Perl Monk, Perl Meditation | |
PerlMonks |
Re^2: How best to compare hash values?by toolic (Bishop) |
on May 06, 2010 at 16:44 UTC ( [id://838748]=note: print w/replies, xml ) | Need Help?? |
my %hash1 = (); # Initialize empty hash. Perhaps unnecessary?Yes, this is unnecessary. Either:
or:
Fat commas are nice too: 1 => 20, I created a sub "isNull" as a homegrown replacement for "exists". The idea is to check your assumptions (and data) before you operate on that data.Your isNull sub is not need with your data. Try:
instead of:
In Section
Seekers of Perl Wisdom
|
|