in reply to multi dimensional hash
Another trick is to use a hash-key like "$hash1|hash2" with a single hash, so that the key is something like "The|the". Auto-vivification takes care of adding new keys to the hash (with initial value zero). When the time comes, you simply split() the hash-key strings.