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

Re: grep & take part of match

by Perlbotics (Chancellor)
on Jun 28, 2012 at 21:03 UTC ( #979000=note: print w/replies, xml ) Need Help??


in reply to grep & take part of match

Another option is to use the indirect loop of/within map:

my @eFILES = map { substr($_, -3) } grep { (!/^\./) && (/^env\.[a-z]{3}$/) && (!/^env\.fix$ +/)&& -f "$LIBDIR/$_" } readdir( LDIR );

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://979000]
help
Chatterbox?
[erix]: I think it depends on the server
[erix]: hmm...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (6)
As of 2017-11-18 21:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:













    Results (278 votes). Check out past polls.

    Notices?