Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^2: Is there an easy way to assign guaranteed unique values to a simple array without looping through whole array?

by mreece (Friar)
on Nov 30, 2007 at 04:35 UTC ( [id://654037]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
        map { $h{$_}++ == 0 ? $_ : () } @_;
    
  2. or download this
        grep { !$h{$_}++ } @_;
    

Log In?
Username:
Password:

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

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

    No recent polls found