smackdab has asked for the wisdom of the Perl Monks concerning the following question:
So GetHash($part1, $part2) would try and return:$hash{part1}{""} = 100; $hash{part1}{part2} = 200;
I think this will work, but could use your advice frist ;-)$hash{part1}{part2} || $hash{part1}{""};
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: "" in hash as a default?
by tadman (Prior) on Mar 23, 2002 at 00:26 UTC |