PROGRAMMER TUTORIALS
solutions to programmer problems

ASP
C#
C++
COBOL
Delphi
HTML
Java
J2EE
JavaScript
JSP
.NET
Perl
PHP
SQL
Visual Basic
XML
View Shopping Cart


Get a FREE Apple iPod Photo

  Books Learning Perl Objects, References, and Modules

Rating: 5 out of 5 stars - exactly what it claims to be
This book provides exactly what it promises: a clear, concise, and complete explanation of how one uses objects, references, and modules in the Perl programming language. The didactic style does an excellent job of explaining concepts in straightforward terms, and maintains a light, conversational tone so that the reader doesn't fall asleep. For those who have a genuine interest in programming, and who enjoy learning new things, PORM encourages this and plays to it, to good effect. As a second Perl book after Learning Perl, I recommend it without hesitation.

Now for the bad news: this is an old book. The later editions have been renamed "Intermediate Perl", and more directly follows on the heels of Learning Perl. At the time of this writing, I have not read Intermediate Perl and cannot comment on its quality as an update of PORM, but based on a solid foundation like this it would be difficult to go far wrong.



Rating: 5 out of 5 stars - Important Note - Discontinued
New editions of this book are no longer in the works, as this title is being discontinued. O'Reilly's "Intermediate Perl" by the same authors (Randal L. Schwartz, brian d foy, and Tom Phoenix) is the new edition of this book. The first edition of "Intermediate Perl" was released March 2006. So if you're thinking about purchasing this book, purchase "Intermediate Perl" instead. It includes the same material (albeit updated) by the same authors. Once again, this title has been discontinued.



Rating: 4 out of 5 stars - "Evolutionary" method to explain Perl Structures, References, Objects
This book attempts something very interesting: not just to describe "how" central aspects of Perl work, but also to understand the process of "how Perl got there". Thus, the book does not serve the "conclusions" right away; it reaches them via a series of experimentations and improvements (in fact, similarly to what is done in other sciences).
To make it interesting (and humorous but realistic at the same time) the book presents a band of "software sailors", who write navigation software. They quickly discover the pleasures of workgroup development; they start reusing software with "eval" (on library files), they then limit unwanted effects with "do", to finally adopt "require" to pull a file only once. Then, after chaos still erupts on name collisions (two different "turn_to_port" routines with the same name, which send one boat into a loop..), the sailors discover "package", and finally, the fleet can proceed with a certain harmony [note: given the structure of the book, "use" will be introduced a lot later, in chapter 12].
This is a very original software lesson; for anyone who reads chapter 2, it will be hard to see the line "package Xyz" and not smile remembering (at least once) the conflicts between Skipper & Gilligan. This is great teaching, as your mind associates a "scenario", not just a "habit", to a programming line.

There are other chapters equally brilliant; more than the "Object" chapters, I liked especially the one on "Subroutine References". It begins explaining how to reference a named subroutine, and it then builds a hash of sub references. Then, it prods us to do the next logical step (with a trick which recurs along the book: "why waste some brain cells to define a name for each subroutine, to only use it to initialize the data structure?"), gently pushing the reader to accept "anonymous" subroutines, code them in the hash structure itself, and enjoy the remarkable simplification of the code that results! The stage is now set to introduce "Callbacks", and then "Closures"; again, with the same method of "one evolution at the time":
a) first a variable is declared to hold the callback, followed by a naked block with a private context and the callback assignment.
b) then the code is simplified with a subroutine encharged to contain the variables on which the closure is done and to return the reference to the anonymous subroutine.
c) last, it shows how the same subroutine can be invoked simultaneously, keeping its own context in every call.
I must say that, after you begin to realize the power of "Closures" (I went back to read "Programming Perl", p 260-262, to fully understand it), you regret that the only example given by the book is so elementary (findFile). Imagine instead, to remain with the sailors theme, a routine which computes a boat trajectory (closing on boat's initial position, velocity, etc), and a main routine instantiating multiple boats and launching them in a race. Multiple automatas in action (with a few lines of code!); this would close the chapter in full glory.

More than once you have the strange feeling that the book was written under a constraint of having less than 200 pages. Examples: it presents a remarkable lesson on Autovivification, but fails to alert against unvoluntary autovivifications (when testing structures for existence).
Or see for, in chapter 2, the section "Packages and Lexicals" whose first line is: "A lexical variable isn't prefixed by the current package because package variables are always global". The statement is not false but it is so awkward at the start a section ("X does not have property Z, because only Y has Z"). Why not to spend a few pages, mentioning the Perl symbol table and on this basis explain concretely the difference between "lexical, global, local"? else, everything remains so abstract.
Still, these are minor defects of an unique remarkable book. The introduction mentions that the material is built on the Stonehenge courses; for all of us without the opportunity to attend them, but able to read, think and experiment, this book is an excellent deal to "see" the Stonehenge people in action.



Rating: 4 out of 5 stars - Great book
This book is perfect if you want to expand your perl horizon. It only gets 4 stars because, hey, I can't give everything five stars.



Rating: 5 out of 5 stars - Definitely a Great Addition to any Perl Library
This book is great for just learning about OO concepts and their related functioning in Perl. Most of the other important Perl texts are very large and tend to summarize many concepts. This text takes Perl OO concepts and presents them in a very interesting and helpful format that is easy to follow. Perl is more than just a scripting language and this text helps you to understand this language from a different prospective.


page 1 of  3
 1  2  3 


2000-2006 ProgrammerTutorials.com


Top100WebShops.com