Intermediate Perl

( 1 )

Overview

This book picks up right where Learning Perl leaves off. With Intermediate Perl, you’ll graduate from short scripts to much larger programs, using features that make Perl a general-purpose language. This gentle but thorough guide introduces you to modules, complex data structures, and object-oriented programming.

Each chapter is small enough to be read in just an hour or two, ending with exercises to help you practice what you’ve learned. If you’re familiar with the material in ...

See more details below
Paperback (2nd ed.)
$29.59
BN.com price
(Save 26%)$39.99 List Price
Other sellers (Paperback)
  • All (19) from $1.99   
  • New (1) from $59.10   
  • Used (18) from $1.99   

Overview

This book picks up right where Learning Perl leaves off. With Intermediate Perl, you’ll graduate from short scripts to much larger programs, using features that make Perl a general-purpose language. This gentle but thorough guide introduces you to modules, complex data structures, and object-oriented programming.

Each chapter is small enough to be read in just an hour or two, ending with exercises to help you practice what you’ve learned. If you’re familiar with the material in Learning Perl and have the ambition to go further, Intermediate Perl will teach you most of the core Perl language concepts you need for writing robust programs on any platform.

Topics include:

  • Packages and namespaces
  • References and scoping, including regular expression references
  • Manipulating complex data structures
  • Object-oriented programming
  • Writing and using modules
  • Testing Perl code
  • Contributing to CPAN

Just like Learning Perl, material in this book closely follows the popular introductory Perl course the authors have taught since 1991. This second edition covers recent changes to the language up to version 5.14.

Described as the book that turns the Perl dabbler into the Perl programmer, this book is about making the leap from the easy things to the hard ones. It is written by the bestselling authors of "Learning Pearl" and offers a gentle but thorough introduction to intermediate programming in Perl.

Read More Show Less

Editorial Reviews

From Barnes & Noble
The Barnes & Noble Review
In Intermediate Perl, Perl legend Randal Schwartz, Tom Phoenix, and Brian Foy pick up where their classic Learning Perl left off. If you can write a basic Perl script, this book will help you write code that’s far more powerful and useful.

Up front, you’ll master some Perl idioms that’ll serve you well and learn to make the most of Perl’s huge library of modules. (Later on, there’s coverage of building your own modules.) Intermediate Perl presents extensive coverage of references, including nested element references, scoping, subroutine and filehandle references, even recursively defined data. You’ll learn to work with complex data structures; use namespaces without causing collisions; make more effective use of objects; even do some fairly serious testing.

Sure, there may be “more than one way to do it” in Perl. But when these authors tell you how, you know it’ll work. Bill Camarda, from the May 2006 Read Only

Read More Show Less

Product Details

  • ISBN-13: 9780596102067
  • Publisher: O'Reilly Media, Incorporated
  • Publication date: 3/15/2006
  • Edition description: 2nd ed.
  • Edition number: 1
  • Pages: 280
  • Product dimensions: 6.90 (w) x 9.40 (h) x 0.70 (d)

Meet the Author

Randal L. Schwartz is a two-decade veteran of the software industry. He is skilled in software design, system administration, security, technical writing, and training. Randal has coauthored the "must-have" standards: Programming Perl, Learning Perl, Learning Perl for Win32 Systems, and Effective Perl Learning, and is a regular columnist for WebTechniques, PerformanceComputing, SysAdmin, and Linux magazines.

He is also a frequent contributor to the Perl newsgroups, and has moderated comp.lang.perl.announce since its inception. His offbeat humor and technical mastery have reached legendary proportions worldwide (but he probably started some of those legends himself). Randal's desire to give back to the Perl community inspired him to help create and provide initial funding for The Perl Institute. He is also a founding board member of the Perl Mongers (perl.org), the worldwide Perl grassroots advocacy organization. Since 1985, Randal has owned and operated Stonehenge Consulting Services, Inc. Randal can be reached for comment at merlyn@stonehenge.com or (503) 777-0095, and welcomes questions on Perl and other related topics.

brian d foy has been an instructor for Stonehenge Consulting Services since 1998, a Perl user since he was a physics graduate student, and a die-hard Mac user since he first owned a computer. He founded the first Perl user group, the New York Perl Mongers, as well as the Perl advocacy nonprofit Perl Mongers, Inc., which helped form more than 200 Perl user groups across the globe. He maintains the perlfaq portions of the core Perl documentation, several modules on CPAN, and some stand-alone scripts. He's the publisher of The Perl Review, a magazine devoted to Perl, and is a frequent speaker at conferences including the Perl Conference, Perl University, MarcusEvans BioInformatics '02, and YAPC. His writings on Perl appear in The O'Reilly Network, The Perl Journal, Dr. Dobbs, and The Perl Review, on use.perl.org, and in several Perl usenet groups.

Tom Phoenix has been working in the field of education since 1982. After more than thirteen years of dissections, explosions, work with interesting animals, and high-voltage sparks during his work at a science museum, he started teaching Perl classes for Stonehenge Consulting Services, where he's worked since 1996. Since then, he has traveled to many interesting locations, so you might see him soon at a Perl Mongers' meeting. When he has time, he answers questions on Usenet's comp.lang.perl.misc and comp.lang.perl.moderated newsgroups, and contributes to the development and usefulness of Perl. Besides his work with Perl, Perl hackers, and related topics, Tom spends his time on amateur cryptography and speaking Esperanto. His home is in Portland, Oregon.

Read More Show Less

Table of Contents

Foreword; Preface; Structure of This Book; Conventions Used in This Book; Using Code Examples; Comments and Questions; Safari® Enabled; Acknowledgments; Chapter 1: Introduction; 1.1 What Should You Know Already?; 1.2 What About All Those Footnotes?; 1.3 What's with the Exercises?; 1.4 What If I'm a Perl Course Instructor?; Chapter 2: Intermediate Foundations; 2.1 List Operators; 2.2 Trapping Errors with eval; 2.3 Dynamic Code with eval; 2.4 Exercises; Chapter 3: Using Modules; 3.1 The Standard Distribution; 3.2 Using Modules; 3.3 Functional Interfaces; 3.4 Selecting What to Import; 3.5 Object-Oriented Interfaces; 3.6 A More Typical Object-Oriented Module: Math::BigInt; 3.7 The Comprehensive Perl Archive Network; 3.8 Installing Modules from CPAN; 3.9 Setting the Path at the Right Time; 3.10 Exercises; Chapter 4: Introduction to References; 4.1 Performing the Same Task on Many Arrays; 4.2 Taking a Reference to an Array; 4.3 Dereferencing the Array Reference; 4.4 Getting Our Braces Off; 4.5 Modifying the Array; 4.6 Nested Data Structures; 4.7 Simplifying Nested Element References with Arrows; 4.8 References to Hashes; 4.9 Exercises; Chapter 5: References and Scoping; 5.1 More Than One Reference to Data; 5.2 What If That Was the Name?; 5.3 Reference Counting and Nested Data Structures; 5.4 When Reference Counting Goes Bad; 5.5 Creating an Anonymous Array Directly; 5.6 Creating an Anonymous Hash; 5.7 Autovivification; 5.8 Autovivification and Hashes; 5.9 Exercises; Chapter 6: Manipulating Complex Data Structures; 6.1 Using the Debugger to View Complex Data; 6.2 Viewing Complex Data with Data::Dumper; 6.3 YAML; 6.4 Storing Complex Data with Storable; 6.5 Using the map and grep Operators; 6.6 Applying a Bit of Indirection; 6.7 Selecting and Altering Complex Data; 6.8 Exercises; Chapter 7: Subroutine References; 7.1 Referencing a Named Subroutine; 7.2 Anonymous Subroutines; 7.3 Callbacks; 7.4 Closures; 7.5 Returning a Subroutine from a Subroutine; 7.6 Closure Variables as Inputs; 7.7 Closure Variables as Static Local Variables; 7.8 Exercise; Chapter 8: Filehandle References; 8.1 The Old Way; 8.2 The Improved Way; 8.3 The Even Better Way; 8.4 IO::Handle; 8.5 Directory Handle References; 8.6 Exercises; Chapter 9: Practical Reference Tricks; 9.1 Review of Sorting; 9.2 Sorting with Indices; 9.3 Sorting Efficiently; 9.4 The Schwartzian Transform; 9.5 Multi-Level Sort with the Schwartzian Transform; 9.6 Recursively Defined Data; 9.7 Building Recursively Defined Data; 9.8 Displaying Recursively Defined Data; 9.9 Exercises; Chapter 10: Building Larger Programs; 10.1 The Cure for the Common Code; 10.2 Inserting Code with eval; 10.3 Using do; 10.4 Using require; 10.5 require and @INC; 10.6 The Problem of Namespace Collisions; 10.7 Packages as Namespace Separators; 10.8 Scope of a Package Directive; 10.9 Packages and Lexicals; 10.10 Exercises; Chapter 11: Introduction to Objects; 11.1 If We Could Talk to the Animals...; 11.2 Introducing the Method Invocation Arrow; 11.3 The Extra Parameter of Method Invocation; 11.4 Calling a Second Method to Simplify Things; 11.5 A Few Notes About @ISA; 11.6 Overriding the Methods; 11.7 Starting the Search from a Different Place; 11.8 The SUPER Way of Doing Things; 11.9 What to Do with @_; 11.10 Where We Are So Far...; 11.11 Exercises; Chapter 12: Objects with Data; 12.1 A Horse Is a Horse, of Course of Course—or Is It?; 12.2 Invoking an Instance Method; 12.3 Accessing the Instance Data; 12.4 How to Build a Horse; 12.5 Inheriting the Constructor; 12.6 Making a Method Work with Either Classes or Instances; 12.7 Adding Parameters to a Method; 12.8 More Interesting Instances; 12.9 A Horse of a Different Color; 12.10 Getting Our Deposit Back; 12.11 Don't Look Inside the Box; 12.12 Faster Getters and Setters; 12.13 Getters That Double as Setters; 12.14 Restricting a Method to Class-Only or Instance-Only; 12.15 Exercise; Chapter 13: Object Destruction; 13.1 Cleaning Up After Yourself; 13.2 Nested Object Destruction; 13.3 Beating a Dead Horse; 13.4 Indirect Object Notation; 13.5 Additional Instance Variables in Subclasses; 13.6 Using Class Variables; 13.7 Weakening the Argument; 13.8 Exercise; Chapter 14: Some Advanced Object Topics; 14.1 UNIVERSAL Methods; 14.2 Testing Our Objects for Good Behavior; 14.3 AUTOLOAD as a Last Resort; 14.4 Using AUTOLOAD for Accessors; 14.5 Creating Getters and Setters More Easily; 14.6 Multiple Inheritance; 14.7 Exercises; Chapter 15: Exporter; 15.1 What use Is Doing; 15.2 Importing with Exporter; 15.3 @EXPORT and @EXPORT_OK; 15.4 %EXPORT_TAGS; 15.5 Exporting in a Primarily OO Module; 15.6 Custom Import Routines; 15.7 Exercises; Chapter 16: Writing a Distribution; 16.1 There's More Than One Way To Do It; 1111116.2 Using h2xs; 16.3 Embedded Documentation; 16.4 Controlling the Distribution with Makefile.PL; 16.5 Alternate Installation Locations (PREFIX=...); 16.6 Trivial make test; 16.7 Trivial make install; 16.8 Trivial make dist; 16.9 Using the Alternate Library Location; 16.10 Exercise; Chapter 17: Essential Testing; 17.1 More Tests Mean Better Code; 17.2 A Simple Test Script; 17.3 The Art of Testing; 17.4 The Test Harness; 17.5 Writing Tests with Test::More; 17.6 Testing Object-Oriented Features; 17.7 A Testing To-Do List; 17.8 Skipping Tests; 17.9 More Complex Tests (Multiple Test Scripts); 17.10 Exercise; Chapter 18: Advanced Testing; 18.1 Testing Large Strings; 18.2 Testing Files; 18.3 Testing STDOUT or STDERR; 18.4 Using Mock Objects; 18.5 Testing POD; 18.6 Coverage Testing; 18.7 Writing Your Own Test::* Modules; 18.8 Exercises; Chapter 19: Contributing to CPAN; 19.1 The Comprehensive Perl Archive Network; 19.2 Getting Prepared; 19.3 Preparing Your Distribution; 19.4 Uploading Your Distribution; 19.5 Announcing the Module; 19.6 Testing on Multiple Platforms; 19.7 Consider Writing an Article or Giving a Talk; 19.8 Exercise; Appendix A: Answers to Exercises; A.1 Answers for Chapter 2; A.2 Answers for Chapter 3; A.3 Answers for Chapter 4; A.4 Answers for Chapter 5; A.5 Answers for Chapter 6; A.6 Answer for Chapter 7; A.7 Answers for Chapter 8; A.8 Answers for Chapter 9; A.9 Answers for Chapter 10; A.10 Answers for Chapter 11; A.11 Answer for Chapter 12; A.12 Answer for Chapter 13; A.13 Answers for Chapter 14; A.14 Answers for Chapter 15; A.15 Answer for Chapter 16; A.16 Answer for Chapter 17; A.17 Answers for Chapter 18; A.18 Answer for Chapter 19; Colophon;

Randal L. Schwartz is a renowned expert on the Perl programming language. In addition to writing "Learning Perl" and the first two editions of "Programming Perl", he has been the Perl columnist for UNIX Review, Web Techniques, Sys Admin, and Linux Magazine. He has contributed to a dozen Perl books, and over 200 magazine articles. Randal runs a Perl training and consulting company (Stonehenge Consulting Services), and is highly sought-after as a speaker for his combination of technical skill, comedic timing, and crowd rapport. He's also a pretty good Karaoke singer.

brian d foy has been an instructor for Stonehenge Consulting Services since 1998. He founded the first Perl user group, the New York Perl Mongers, as well as the Perl advocacy nonprofit Perl Mongers, Inc., which helped form more than 200 Perl user groups across the globe. He maintains the perlfaq portions of the core Perl documentation, several modules on CPAN, and some stand-alone scripts. He's the publisher of The Perl Review and is a frequent speaker at conferences. His writings on Perl appear on The O'Reilly Network and use.perl.org, and in The Perl Journal, Dr. Dobbs Journal, and The Perl Review.

Tom Phoenix has been working in the field of education since 1982. After more than thirteen years of dissections, explosions, work with interesting animals, and high-voltage sparks during his work at a science museum, he started teaching Perl classes for Stonehenge Consulting Services, where he's worked since 1996. Since then, he has traveled to many interesting locations, so you might see him soon at a Perl Mongers' meeting. When he has time, he answers questions on Usenet's comp.lang.perl.misc and comp.lang.perl.moderated newsgroups, and contributes to the development and usefulness of Perl. Besides his work with Perl, Perl hackers, and related topics, Tom spends his time on amateur cryptography and speaking Esperanto. His home is in Portland, Oregon.

Read More Show Less

Customer Reviews

Average Rating 5
( 1 )
Rating Distribution

5 Star

(1)

4 Star

(0)

3 Star

(0)

2 Star

(0)

1 Star

(0)

Your Rating:

Your Name: Create a Pen Name or

Barnes & Noble.com Review Rules

Our reader reviews allow you to share your comments on titles you liked, or didn't, with others. By submitting an online review, you are representing to Barnes & Noble.com that all information contained in your review is original and accurate in all respects, and that the submission of such content by you and the posting of such content by Barnes & Noble.com does not and will not violate the rights of any third party. Please follow the rules below to help ensure that your review can be posted.

Reviews by Our Customers Under the Age of 13

We highly value and respect everyone's opinion concerning the titles we offer. However, we cannot allow persons under the age of 13 to have accounts at BN.com or to post customer reviews. Please see our Terms of Use for more details.

What to exclude from your review:

Please do not write about reviews, commentary, or information posted on the product page. If you see any errors in the information on the product page, please send us an email.

Reviews should not contain any of the following:

  • - HTML tags, profanity, obscenities, vulgarities, or comments that defame anyone
  • - Time-sensitive information such as tour dates, signings, lectures, etc.
  • - Single-word reviews. Other people will read your review to discover why you liked or didn't like the title. Be descriptive.
  • - Comments focusing on the author or that may ruin the ending for others
  • - Phone numbers, addresses, URLs
  • - Pricing and availability information or alternative ordering information
  • - Advertisements or commercial solicitation

Reminder:

  • - By submitting a review, you grant to Barnes & Noble.com and its sublicensees the royalty-free, perpetual, irrevocable right and license to use the review in accordance with the Barnes & Noble.com Terms of Use.
  • - Barnes & Noble.com reserves the right not to post any review -- particularly those that do not follow the terms and conditions of these Rules. Barnes & Noble.com also reserves the right to remove any review at any time without notice.
  • - See Terms of Use for other conditions and disclaimers.
Search for Products You'd Like to Recommend

Recommend other products that relate to your review. Just search for them below and share!

Create a Pen Name

Your Pen Name is your unique identity on BN.com. It will appear on the reviews you write and other website activities. Your Pen Name cannot be edited, changed or deleted once submitted.

 
Your Pen Name can be any combination of alphanumeric characters (plus - and _), and must be at least two characters long.

Continue Anonymously
Sort by: Showing 1 Customer Reviews
  • Anonymous

    Posted May 30, 2007

    Indispensable!

    If you've been using Perl for more than a year and you find yourself dealing with increasingly complex data structures, you probably need to get and read this book. It lays out tricks and techniques for storing, manipulating and using deeply layered hashes, arrays, anonymous entities and even references to subroutines. This book is clearly written, full of excellent and illuminating examples, peppered with exercises (and illustrations of possible answers to same) and even amusing now and then. There are a few errors to be found, but errata lists are available from the O'Reilly website so you can be edit them out yourself before you even read it. I review a chapter of this book weekly, and it has dramatically improved my productivity as a Perl programmer. As the title of this review says, this book is indispensable.

    Was this review helpful? Yes  No   Report this review
Sort by: Showing 1 Customer Reviews

If you find inappropriate content, please report it to Barnes & Noble
Why is this product inappropriate?
Comments (optional)