in reply to Re: Re: HoH and accumulation
in thread HoH and accumulation

I'm sorry, that was due to a typo on my part (I did warn that the code was untested).

You need to write $subhash->{$key} and not $subhash{$key} because you need to dereference the scalar $subhash, not access %subhash. (As I note in my update, strict.pm catches this kind of bug for you.)

If this fix confuses you, then I'd highly recommend reading references quick reference.