Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: Conditional Map?

by blakem (Monsignor)
on Oct 07, 2002 at 11:45 UTC ( [id://203294]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my @evens = map { $_%2 ? () : $_ } 1..10;
    
  2. or download this
    my %hash = map { /^f/ ? () 
                          : (getkey($_) => $_) }
               @array;
    

Log In?
Username:
Password:

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

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

    No recent polls found