A simple solution is two concatenate the two keys into one with a seldom used character. In fact, that's what Perl does internally when you give several keys to index a hash:
$myhash{'key1', 'key2'};is equivalent to:
$myhash{join("\x1c", 'key1', 'key2')};ASCII 28 is considered a seldom used character, but you may use another one by changing $;.
Needless to say this is widely considered dirty. davorg's suggestion of using a hash of hashes of arrays is a lot neater.
HTH
--bwana147
In reply to Re: multidimensional hash of array
by bwana147
in thread multidimensional hash of array
by kevyt
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |