Introduction to Perl Programming Essentials

Hands-on Perl Scripting | Learn, Use & Leverage the Perl Scripting Library

TTPS4925

Introductory

5 Days

Course Overview

Introduction to Perl Programming Essentials is an Introductory-level practical, hands-on Perl scripting training course that that guides the students from the basics of writing and running Perl scripts to using more advanced features such as file operations, report writing, the use of regular expressions, working with binary data files, and using the extensive functionality of the standard Perl library.  Students will immediately be able to use Perl to complete tasks in the real world.

Course Topics Covered: Throughout the course, students will learn about and explore:

  • Executing programs
  • Variables and constants
  • Conditions and iterations
  • Arrays and hashes
  • Working with Files
  • Output formatting
  • References and data structures
  • Regular Expressions
  • Subroutines
  • Working with the Operating System
  • Shortcuts and Defaults
  • Using the Standard Library

 

Course Objectives

Throughout the course students will be led through a series of progressively advanced topics, where each topic consists of lecture, group discussion, comprehensive hands-on lab exercises, and lab review. This course is “skills-centric”, designed to train attendees in core Perl and web development skills beyond an intermediate level, coupling the most current, effective techniques with best practices.

Working within in an engaging, hands-on learning environment, guided by our expert web development, PHP practitioner, students will learn to:

  • Create a working script that gets input from the command line, the keyboard, or a file
  • Use arrays to store and process data from files
  • Create formatted reports
  • Use regular expressions
  • Use the appropriate types of variables and data structures
  • Refactor duplicate code into subroutines and modules
  • What is available in the standard library
  • Use shortcuts and defaults, and what they replace

Need different skills or topics?  If your team requires different topics or tools, additional skills or custom approach, this course may be further adjusted to accommodate.  We offer additional Perl, Python, web development, data science, machine learning and other related topics that may be blended with this course for a track that best suits your needs. Our team will collaborate with you to understand your needs and will target the course to focus on your specific learning objectives and goals.

Course Prerequisites

This course is appropriate for anyone who wants to create applications or modules to automate and simplify common tasks with Perl.  Students should already have a working, user-level knowledge of an operating system such as UNIX or Windows. While not mandatory, basic skills with at least one other programming language are desirable.

Course Agenda

Please note that this list of topics is based on our standard course offering, evolved from typical industry uses and trends. We will work with you to tune this course and level of coverage to target the skills you need most.

Session: An Overview of Perl

  • What is Perl?
  • Perl is compiled and interpreted
  • Perl Advantages and Disadvantages
  • Downloading and Installing Perl
  • Which version of Perl
  • Getting Help

Session: Creating and running Perl Programs

  • Structure of a Perl program
  • Running a Perl script
  • Checking syntax and warnings
  • Execution of scripts under Unix and Windows

Session: Basic Data and I/O

  • Numeric and Text literals
  • Math operators and expressions
  • Scalar variables
  • Default values
  • Writing to standard output
  • Command line arguments
  • Reading from the standard input

Session: Logic and Loops

  • About flow control
  • The if statement and Boolean values
  • Using unless and elsif
  • Statement modifiers
  • warn() and die()
  • The conditional construct
  • Using while loop and its variants
  • Using the for loop
  • Exiting from loops

Session: Lists and Arrays

  • The list data type
  • Accessing array elements
  • Creating arrays
  • List interpolation
  • Arrays and memory
  • Counting elements
  • Iterating through an array
  • List evaluation
  • Slices and ranges

Session: Reading and writing text files

  • File I/O Overview
  • Opening a file
  • Reading text files
  • Writing to a text file
  • Arrays and file I/O
  • Using the <> operator

Session: List functions

  • Growing and shrinking arrays
  • The split() function
  • Splitting on whitespace
  • Assigning to literal lists
  • The join() function
  • The sort() function
  • Alternate sort keys
  • Reversing an array

Session: Formatting output

  • Using sprintf() and printf()
  • Report formatting overview
  • Defining report formats
  • The write() function
  • Advanced filehandle magic

Session: Hashes

  • Hash overview
  • Creating hashes
  • Hash attributes
  • Traversing a hash
  • Testing for existence of elements
  • Deleting hash elements

Session: References

  • What is a reference?
  • The two ways to create references
  • References to existing data
  • References to anonymous data
  • Dereferencing scalar, array, and ash references
  • Dereferencing elements of arrays and hashes
  • Multidimensional arrays and other data structures

Session: Text and Regular Expressions

  • String length
  • The substr() function
  • The index() and rindex() functions
  • String replication
  • Pattern matching and substitution
  • Regular expressions

Session: Raw file and data access

  • Opening and closing raw (binary) files
  • Reading raw data
  • Using seek() and tell()
  • Writing raw data
  • Raw data manipulation with pack() and unpack()

Session: Subroutines and variable scope

  • Understanding packages
  • Package and Lexical variables
  • Localizing builtin variables
  • Declaring  and calling subroutines
  • Calling subroutines
  • Passing parameters and returning values

Session: Working with the operating system

  • Determining current OS
  • Environment variables
  • Running external programs
  • User identification
  • Trapping signals
  • File test operators
  • Working with files
  • Time of day

Session: Shortcuts and defaults

  • Understanding $_
  • shift() with no array specified
  • Text file processing
  • Using grep() and Using map()
  • Command-line options for  file processing

Session: Data wrangling

  • Quoting in Perl
  • Evaluating arrays
  • Understanding qw( )
  • Getting more out of the <> operator
  • Read ranges of lines
  • Using m//g in scalar context
  • The /o modifier
  • Working with embedded newlines
  • Making REs more readable
  • Perl data conversion

Session: Using the Perl Library

  • The Perl library
  • Old-style library files
  • Perl modules
  • Modules bundled with Perl
  • A selection of modules
  • Getting modules from ActiveState
  • Getting modules from CPAN
  • Using Getopt::Long

Session: Some Useful Tools

  • Sending and receiving files with Net::FTP
  • Using File::Find to search for files and directories
  • Grabbing a Web page
  • Some good places to find scripts
  • Perl man pages for more information
  • Zipping and unzipping files

Course Materials

Student Materials: Each student will receive a Student Guide with course notes, code samples, software tutorials, diagrams and related reference materials and links (as applicable). Our courses also include step by step hands-on lab instructions and and solutions, clearly illustrated for users to complete hands-on work in class, and to revisit to review or refresh skills at any time. Students will also receive related (as applicable) project files, code files, data sets and solutions required for the hands-on work.

Classroom Setup Made Simple:  Our dedicated tech team will work with you to ensure your classroom and lab environment is setup, tested and ready to go well in advance of the course delivery date, ensuring a smooth start to class and seamless hands-on experience for your students. We offer several flexible student machine setup options including guided manual set up for simple installation directly on student machines, or cloud based / remote hosted lab solutions where students can log in to a complete separate lab environment minus any installations, or we can supply complete turn-key, pre-loaded equipment to bring ready-to-go student machines to your facility.  Please inquire for details, options and pricing

Raise the bar for advancing technology skills

Attend a Class!

Live scheduled classes are listed below or browse our full course catalog anytime

Special Offers

We regulary offer discounts for individuals, groups and corporate teams. Contact us

Custom Team Training

Check out custom training solutions planned around your unique needs and skills.

EveryCourse Extras

Exclusive materials, ongoing support and a free live course refresh with every class.

Attend a Course

Please see the current upcoming available open enrollment course dates posted below. Please feel free to Register Online below, or call 844-475-4559 toll free to connect with our Registrar for assistance. If you need additional date options, please contact us for scheduling.

Course Title Days Date Time Price
Introduction to Perl Programming Essentials 5 Days Aug 30 to Sep 2 10:00 AM to 06:00 PM EST $2,595.00 Enroll
Introduction to Perl Programming Essentials 5 Days Oct 18 to Oct 21 10:00 AM to 06:00 PM EST $2,595.00 Enroll
Introduction to Perl Programming Essentials 5 Days Nov 30 to Dec 3 10:00 AM to 06:00 PM EST $2,595.00 Enroll

New Site, BIG Savings!
We're celebrating the launch of our lonnngggg awaited new site with with *50% off all 2021 Public Classes* booked by April 30!  Check out our Current Offers for Individuals, Teams and Organizations to Learn for Less!

See our latest Offers and Promotions

Learn. Explore. Advance!

Extend your training investment! Recorded sessions, free re-sits and after course support included with Every Course
Trivera MiniCamps
Gain the skills you need with less time in the classroom with our short course, live-online hands-on events
Trivera QuickSkills: Free Courses and Webinars
Training on us! Keep your skills current with free live events, courses & webinars
Trivera AfterCourse: Coaching and Support
Expert level after-training support to help organizations put new training skills into practice on the job

The voices of our customers speak volumes

Special Offers
Limited Offer for most courses.

SAVE 50%

Learn More