|Pathologically Eclectic Rubbish Lister|
question for perl book & magazine authorsby jfroebe (Parson)
|on Oct 19, 2005 at 20:49 UTC||Need Help??|
jfroebe has asked for the wisdom of the Perl Monks concerning the following question:
I've been reading a book on DBMS administration using perl (specific book doesn't matter) and have seen this in other perl books as well. (I'm not singling out any author)
Several books tend to avoid the use of map and grep. I can only assume that the authors have trouble explaining the usage and benefits of these in such a way that perl programmers can understand. How can we explain map and grep better?
One of the benefits is that often, using map or grep provides increased performance (see example below). Another is that you can chain the greps and maps together to make your life so much easier.
I'm convinced that map & grep aren't as heavily used as they could be because people don't understand them.
Jason L. Froebe
No one has seen what you have seen, and until that happens, we're all going to think that you're nuts. - Jack O'Neil, Stargate SG-1