We don't bite newbies here... much | |
PerlMonks |
Re: Comparing all keys in a hashby gmax (Abbot) |
on Mar 20, 2003 at 12:03 UTC ( [id://244573]=note: print w/replies, xml ) | Need Help?? |
Actually, the way you are doing it, you are comparing arrays. Therefore you may find useful this node: The best method there was MeowChow's at (MeowChow) Re2: (Efficiently) comparing arrays To take advantage of hashes capabilities, though, I would rather use something like
The first sub returns an array of keys present in one hash and missing in the other one. The second one combines the differences in both hashes. I think you may use this method to implement what is closer to your needs. _ _ _ _ (_|| | |(_|>< _|
In Section
Meditations
|
|