Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re^3: Need help understanding code snippet with "grep -f"

by GrandFather (Saint)
on Dec 23, 2015 at 08:47 UTC ( #1151009=note: print w/replies, xml ) Need Help??


in reply to Re^2: Need help understanding code snippet with "grep -f"
in thread Need help understanding code snippet with "grep -f"

The map is useful if you have a list containing more than one item. As I said in my OP the grep is redundant if you are using glob.

Premature optimization is the root of all job security
  • Comment on Re^3: Need help understanding code snippet with "grep -f"

Replies are listed 'Best First'.
Re^4: Need help understanding code snippet with "grep -f"
by Marshall (Canon) on Dec 23, 2015 at 09:28 UTC
    I think the OP has working code and all is fine.

    I don't see any reason at all to quibble. The Perl map{} especially in conjunction with Perl grep{} in the comma format can be hard to understand.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (9)
As of 2021-04-13 13:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?