As regular readers of this blog know, I’m just getting acquainted with Perl, which is to say that I started programming in Perl in the early ’90s but as an occasional thing. Only recently, with my renewed interest in scraping Webpages and using Web APIs have I really started to get my hands dirty with Perl scripts more than a line or two long.
Therefore, I was particularly pleased to be given a chance to review Steve Oualline’s new Wicked Cool Perl Scripts book (Feb 2006, No Starch Press). It offers collections of ready-to-use code snippets that raise the abstraction level from the basic “how do I express something in Perl” up to “how do I get a particular coding job done”.
The book is split into 11 chapters, with topics ranging from CGI programs to Internet Data Mining to Games and Learning tools. Each of these topics has a definite point of view, and a set of problems they intend to help with. It was a bit of a shift to read through these, because I’d been expecting topics much more data-type oriented, such as Tricks with Strings or Fantastic File Manipulation, which is not what this book offers.
The biggest problem when offering such task-specific examples is that it’s really hard to use the book to solve particular problems that lie outside the book’s narrative, let alone transfer what you learn from the book into new problem solving. Another problem is that the task-specific examples have a lot of overhead. Cool Script #41, for example, is a Map Generator which runs on for 14 pages, with much of its code even to my non-Perl eyes being a bit weak and redundant. It’s great if you actually need a Map Generator. Less great if you intend to use the principles from the example in another application.
On the up side, the examples are all easy to follow with excellent narrative. I very much liked the way the code was laid out for reading and then discussed. Oualline clearly put a lot of effort into presenting this material to his audience, which is Unix-savvy beginning-to-intermediate Perl programmers.
It’s hard to fault a book for being what it is and not what you had hoped it would be. Wicked Cool Perl Scripts provides excellent and useful scripts to do the specific things the author intends them to be used for. Before buying, I recommend you read through the table of contents. See whether the book includes the right solutions for your personal problems. If so, Wicked Cool Perl Scripts may save you a great deal of time and effort.
Have you read Wicked Cool Perl Scripts? I’d be interested in hearing your opinions in the comments.


I have two other Oualline books and will, therefore, not be reading Wicked Cool Perl Scripts. His writing is dull, repetitive, and poorly organized, and I don't understand how he keeps getting published.
The best book for snippets of Perl organized by topic is the Perl Cookbook, published by that company that puts animals on its covers.
Before buying, I recommend you read through the table of contents.
Gosh. Wouldn't it be nice if O'Reilly allowed us to do that online?
Sadly, their concept of browsing "within the book" is to give us a bigger picture of the cover... Thanks guys.
"Gosh. Wouldn't it be nice if O'Reilly allowed us to do that online?"
I was going to retort that you can browse the contents (and sample chapters) at O'Reilly's site; but then I went and looked, and that doesn't seem to be possible anymore! It appears the site's been redesigned, with a look and feel suspiciously similar to Amazon's, and there is a whole lot less information available.
I have to chime in: "Thanks guys". What's O'Reilly up to??
I love Steve's book on vim, but I wasn't very impressed with what I saw in WCPS, from leafing through it at Borders.
There's an interview with him at perlcast.com, if you're interested.
Dr Drang mentioned the Perl Cookbook, and from your expectations as per the first paragraph I think you should grab that post-haste (assuming it's not already gracing your shelves). It's great for dipping into once in a while and really helpful when a specific need arises.
Granted I don't work for the book side of the company, but "No Starch" is a partner publisher of O'Reilly, which means we only handle things like printing, distribution and some marketing (but don't quote me on that).
It's also means, we don't have the rights to expose as much content about the book online as we do say for our other books, e.g. The Perl Cookbook's Table of Contents.
Otherwise the only thing that has changed are the design of the catalog pages in an effort to give you a deeper look into the book (a la Amazon's search inside the book).