in reply to Re^4: Possible for Map to create Hash of Hash?
in thread Possible for Map to create Hash of Hash?
he can also use things like keys %{$hash{$store}} to list all products.Agree. But does he need to?
neither shorter to write
It's shorter to write: "$h{$s,$p}" 9 characters. "$h{$s}{$p}" 10 characters. + code to populate hash is simpler.
nor more efficient
Maybe memory usage is not important in this case? And maybe serialization/deserialization time is more important. Who knows.
Also, perl has a special notation for it. That makes me think it's a useful feature for some cases.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^6: Possible for Map to create Hash of Hash?
by Anonymous Monk on May 11, 2013 at 14:56 UTC | |
by LanX (Saint) on May 11, 2013 at 15:44 UTC |