Associates; ISBN 1-56592-149-6; $39.95
Although Perl 5, the much-evolved version of the ubiquitous scripting language, has been available for over two years, books about it are scarce. Up to now, if you wanted to use Perl 5's new advanced features, including compound structures, object-oriented abilities, dynamically linked modules and extensions, and improved variable scoping, you had to grovel through Perl 5's technical documentation with your Perl 4 book also open by your side.
Two books that now help fill this void
are
Perl 5 Interactive Course
, by Jon Orwant, and
Programming Perl--Second Edition
, by Wall, Christiansen, and Schwartz. These two books are radically different in style.
Each of the 14 chapters in Orwant's book has eight "sessions," each one ending in a four-question multiple-choice quiz and an exercise. Each chapter has its own quiz and exercises as well. This book is rigidly organized. The author wrote it for the reader who prefers to learn in a classroom rather than in a lab or in the real world. He assumes the reader has little or no programming experience, yet he covers even the advanced features of dynamic linking, C functions and libraries as extensions to Perl, and Perl as an extension to C programs.
Orwant knows his material: He uses Perl in his work at MIT's Media Lab and is the editor of the
Perl Journal
. But the book's weaknesses (i.e., the approach that favors classroom lessons over real-world ones) are due to the restrictions, planning, and editing inflicted b
y the publisher.
Like other books by O'Reilly & Associates,
Programming Perl--2nd Edition
features an engraving of an animal on its cover. The definitive reference to the Perl 4 programming language is affectionately known as the "Camel Book." The second edition, although its content and list of authors are considerably expanded from the first edition, still sports an image of a camel on the cover.
The new edition includes revisions to the first one, plus it adds almost 200 pages that cover Perl 5. The new edition is reorganized appropriately for Perl 5, which is itself a total rewrite and reorganization of Perl 4 that maintains almost perfect backward compatibility.
The primary author of
Programming Perl--2nd Edition
is also the primary architect and programmer of Perl, Larry Wall. His writing is loaded with a refreshingly wry humor and a sense of companionship with his readers. Wall's coauthor Tom Christiansen has been lecturing about and teaching Perl since its early days;
when Perl 5 arrived, he was the bard of its new ability to do compound structures and dereferencing of variables. Randal L. Schwartz, who contributed much of the work in putting together the first edition, also assisted with the editing and management of this edition.
The Perl 5 distribution comes with a considerable amount of documentation in the clever form of Perl Online Documentation (POD), a code-embeddable markup language that you can use to generate Hypertext Markup Language (HTML), PostScript, and plain-text output. From now on, POD will be the definitive documentation for Perl, since it's updated with new revisions and additions to Perl. The second-edition Camel Book merges these documents with the first-edition text and also adds a welcome dose of humor and organization, as well as examples.
The only fault with this book is that the examples may be too clever for the average Perl programmer. Otherwise, the Camel Book reigns again as the definitive text on Perl.