Books & Videos

Table of Contents

  1. Chapter 1 Introduction

    1. Questions and Answers

    2. What Does “Perl” Stand For?

    3. How Can I Get Perl?

    4. How Do I Make a Perl Program?

    5. A Whirlwind Tour of Perl

    6. Exercises

  2. Chapter 2 Scalar Data

    1. Numbers

    2. Strings

    3. Perl’s Built-in Warnings

    4. Scalar Variables

    5. Output with print

    6. The if Control Structure

    7. Getting User Input

    8. The chomp Operator

    9. The while Control Structure

    10. The undef Value

    11. The defined Function

    12. Exercises

  3. Chapter 3 Lists and Arrays

    1. Accessing Elements of an Array

    2. Special Array Indices

    3. List Literals

    4. List Assignment

    5. Interpolating Arrays into Strings

    6. The foreach Control Structure

    7. Scalar and List Context

    8. <STDIN> in List Context

    9. Exercises

  4. Chapter 4 Subroutines

    1. Defining a Subroutine

    2. Invoking a Subroutine

    3. Return Values

    4. Arguments

    5. Private Variables in Subroutines

    6. Variable-Length Parameter Lists

    7. Notes on Lexical (my) Variables

    8. The use strict Pragma

    9. The return Operator

    10. Non-Scalar Return Values

    11. Persistent, Private Variables

    12. Exercises

  5. Chapter 5 Input and Output

    1. Input from Standard Input

    2. Input from the Diamond Operator

    3. The Invocation Arguments

    4. Output to Standard Output

    5. Formatted Output with printf

    6. Filehandles

    7. Opening a Filehandle

    8. Fatal Errors with die

    9. Using Filehandles

    10. Reopening a Standard Filehandle

    11. Output with say

    12. Filehandles in a Scalar

    13. Exercises

  6. Chapter 6 Hashes

    1. What Is a Hash?

    2. Hash Element Access

    3. Hash Functions

    4. Typical Use of a Hash

    5. The %ENV hash

    6. Exercises

  7. Chapter 7 In the World of Regular Expressions

    1. What Are Regular Expressions?

    2. Using Simple Patterns

    3. Character Classes

    4. Exercises

  8. Chapter 8 Matching with Regular Expressions

    1. Matches with m//

    2. Match Modifiers

    3. Anchors

    4. The Binding Operator =~

    5. Interpolating into Patterns

    6. The Match Variables

    7. General Quantifiers

    8. Precedence

    9. A Pattern Test Program

    10. Exercises

  9. Chapter 9 Processing Text with Regular Expressions

    1. Substitutions with s///

    2. The split Operator

    3. The join Function

    4. m// in List Context

    5. More Powerful Regular Expressions

    6. Exercises

  10. Chapter 10 More Control Structures

    1. The unless Control Structure

    2. The until Control Structure

    3. Expression Modifiers

    4. The Naked Block Control Structure

    5. The elsif Clause

    6. Autoincrement and Autodecrement

    7. The for Control Structure

    8. Loop Controls

    9. The Conditional Operator ?:

    10. Logical Operators

    11. Exercises

  11. Chapter 11 Perl Modules

    1. Finding Modules

    2. Installing Modules

    3. Using Simple Modules

    4. Exercises

  12. Chapter 12 File Tests

    1. File Test Operators

    2. The stat and lstat Functions

    3. The localtime Function

    4. Bitwise Operators

    5. Exercises

  13. Chapter 13 Directory Operations

    1. Moving Around the Directory Tree

    2. Globbing

    3. An Alternate Syntax for Globbing

    4. Directory Handles

    5. Recursive Directory Listing

    6. Manipulating Files and Directories

    7. Removing Files

    8. Renaming Files

    9. Links and Files

    10. Making and Removing Directories

    11. Modifying Permissions

    12. Changing Ownership

    13. Changing Timestamps

    14. Exercises

  14. Chapter 14 Strings and Sorting

    1. Finding a Substring with index

    2. Manipulating a Substring with substr

    3. Formatting Data with sprintf

    4. Advanced Sorting

    5. Exercises

  15. Chapter 15 Smart Matching and given-when

    1. The Smart Match Operator

    2. Smart Match Precedence

    3. The given Statement

    4. Using when with Many Items

    5. Exercises

  16. Chapter 16 Process Management

    1. The system Function

    2. The Environment Variables

    3. The exec Function

    4. Using Backquotes to Capture Output

    5. External Processes with IPC::System::Simple

    6. Processes as Filehandles

    7. Getting Down and Dirty with Fork

    8. Sending and Receiving Signals

    9. Exercises

  17. Chapter 17 Some Advanced Perl Techniques

    1. Slices

    2. Trapping Errors

    3. Picking Items from a List with grep

    4. Transforming Items from a List with map

    5. Fancier List Utilities

    6. Exercises

  1. Appendix Exercise Answers

    1. Answers to Chapter 1 Exercises

    2. Answers to Chapter 2 Exercises

    3. Answers to Chapter 3 Exercises

    4. Answers to Chapter 4 Exercises

    5. Answers to Chapter 5 Exercises

    6. Answers to Chapter 6 Exercises

    7. Answers to Chapter 7 Exercises

    8. Answers to Chapter 8 Exercises

    9. Answers to Chapter 9 Exercises

    10. Answers to Chapter 10 Exercises

    11. Answer to Chapter 11 Exercises

    12. Answers to Chapter 12 Exercises

    13. Answers to Chapter 13 Exercises

    14. Answers to Chapter 14 Exercises

    15. Answers to Chapter 15 Exercises

    16. Answers to Chapter 16 Exercises

    17. Answer to Chapter 17 Exercises

  2. Appendix Beyond the Llama

    1. Further Documentation

    2. Regular Expressions

    3. Packages

    4. Extending Perl’s Functionality

    5. Databases

    6. Other Operators and Functions

    7. Mathematics

    8. Lists and Arrays

    9. Bits and Pieces

    10. Formats

    11. Networking and IPC

    12. Security

    13. Debugging

    14. Command-Line Options

    15. Built-in Variables

    16. Syntax Extensions

    17. References

    18. Tied Variables

    19. Operator Overloading

    20. Dynamic Loading

    21. Embedding

    22. Converting Other Languages to Perl

    23. Converting find Command Lines to Perl

    24. Command-Line Options in Your Programs

    25. Embedded Documentation

    26. More Ways to Open Filehandles

    27. Threads and Forking

    28. Graphical User Interfaces (GUIs)

    29. And More…

  3. Appendix A Unicode Primer

    1. Unicode

    2. UTF-8 and Friends

    3. Getting Everyone to Agree

    4. Fancy Characters

    5. Dealing with Unicode in Perl

    6. Further Reading

  4. Colophon