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

Re^3: how to quickly tell if number is in an array

by McDarren (Abbot)
on Oct 12, 2005 at 02:23 UTC ( [id://499344]=note: print w/replies, xml ) Need Help??


in reply to Re^2: how to quickly tell if number is in an array
in thread how to quickly tell if number is in an array

whoops!
Okay... how about...
print "found\n" if grep(/^$number\$/, @array);

Replies are listed 'Best First'.
Re^4: how to quickly tell if number is in an array
by BUU (Prior) on Oct 12, 2005 at 02:41 UTC
    So now your using the regex engine.. to test if a number.. is exactly the same as another number?
      yes, this is a bit silly, isn't it.
      I just had a read of the faq on this one, and now I've realised that I need to go back and re-do a few of my utilty scripts...

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others exploiting the Monastery: (3)
As of 2024-04-20 02:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found