Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: Interesting Use of Grep

by Brovnik (Hermit)
on Jun 29, 2001 at 18:36 UTC ( #92641=note: print w/ replies, xml ) Need Help??


in reply to Interesting Use of Grep

It may be overkill, but Quantum::Superpositions allows you to do e.g.

use Quantum::Superpositions; if ($x == any(qw(1 2 3 5 7 9 11))) { print "small Prime\n"; }
which IMHO is nice and readable.
--
Brovnik


Comment on Re: Interesting Use of Grep
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (5)
As of 2014-09-19 03:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (129 votes), past polls