Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re: Unable to Understand grep and hash use for prime no.

by soonix (Canon)
on Aug 04, 2015 at 18:59 UTC ( [id://1137415]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
       my %is_prime;
       @primes = grep { 
    ...
                    or 
                    ( $is_prime{$_} = is_prime($_) )
                 } @numbers;
    

Log In?
Username:
Password:

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

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

    No recent polls found