Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: The fastest way of searching a certain element in an array

by blakem (Monsignor)
on Apr 14, 2004 at 23:49 UTC ( #345252=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    % perldoc List::Util
    
    ...
                   $foo = first { defined($_) } @list    # first defined v
    +alue in @list
                   $foo = first { $_ > $value } @list    # first value in 
    +@list which
                                                         # is greater than
    + $value
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (18)
As of 2014-07-10 19:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    When choosing user names for websites, I prefer to use:








    Results (215 votes), past polls