in reply to Re: which data structure do I need for this grouping problem?
in thread which data structure do I need for this grouping problem?

There is a built-in mechanism for this: see perldoc -v '$;'.