Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: How to get rid of dupes from an array of hashes

by sapnac (Beadle)
on Jul 01, 2005 at 16:14 UTC ( [id://471766]=note: print w/replies, xml ) Need Help??


in reply to How to get rid of dupes from an array of hashes



If this going to be more that once, you are better off creating 4001th hash in the array containing only the unique ones. Everytime you add and element chekc this array add to it too and vola! ur task will be greately reduced.

Just a thought! I really don't know of if you can get uniques without looping less. But per experience, hashes are fast and will not take that much time. Time it with 1000 first.
  • Comment on Re: How to get rid of dupes from an array of hashes

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://471766]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (7)
As of 2024-04-25 08:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found