|
|
| Pathologically Eclectic Rubbish Lister | |
| PerlMonks |
Re^3: Better algorithm or data structure?by johngg (Canon) |
| on Aug 30, 2010 at 01:30 UTC ( [id://857966]=note: print w/replies, xml ) | Need Help?? |
|
How about making each "set" an object rather than just an anonymous array and store references to the objects in the %bools hash. You could then iterate over @someOrder in a loop rather than hash slicing and use the object destructor to take some action when the final reference to a "set" is deleteed from %bools. Just a thought that occurred to me while trying to get to sleep :-/ Cheers, JohnGG
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||||||||||