Udemy
    •  
    •  
    •  
    •  
    •  
    •  
    •  
    •  
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
Learn Perl 5 By Doing It
Rating: 4.2 out of 5(2,751 ratings)
18,023 students

Learn Perl 5 By Doing It

Learn Perl by actually creating useful, working Perl programs for everything from web scraping to fixing your data.
Created byJohn Purcell
Last updated 6/2023
English

What you'll learn

  • Learn how to use Perl for a variety of common tasks
  • Learn how to use regular expressions

Course content

14 sections68 lectures14h 17m total length
  • Installing Perl and Some Great Free Editors11:56
    An overview of what kind of stuff is going to be in the course, various options for installing Perl and a bit about various free editors.
  • Hello World6:19
    A simple "hello world" program in Perl. But not just a one liner .... in fact, we're going to put some stuff in this that will provide us with a great start for any Perl program.
  • Downloading Text And Images - Updated14:26
  • Downloading Text and Images With Perl (Old Version!)14:05

    Note: this will only work on http sites, not https. See previous video.

    In "The Social Network", the character based on Mark Zuckerberg uses Perl to download images from the Internet. It's easier than you think, and we'll see how to do it in this tutorial. NOTE: My website has been updated since this tutorial, so please choose a different image to download other than my logo when you try this tutorial. Or, download my logo, but please be aware that the path has changed. You can easily find the new path by right-clicking the image you want to download in your browser, going to "view image" or the equivalent, and noting the path.

  • Arrays and Checking Whether Files Exist15:03
    Perl is great for moving files around, deleting files, renaming them, etc. Let's take a look at how we can check if a whole batch of files exist, learning to use arrays along the way.
  • Reading Files and Beginning Regular Expressions17:25
    In this tutorial we'll look at how to read text files in Perl. We'll also start looking at regular expressions! Do not be afraid -- soon, with a little practice, regular expressions will be like unto a brother.
  • Writing Files and Replacing Text20:17
    Let's take a look at the important topic of writing text files. After all, perl is great for creating text files, whether you want to record what's going on, scrape stuff from the Internet or just reformat existing text files. We'll also take a look at how we can basically do a "find and replace" with a simple perl regex (regular expression) command.
  • Wildcards in Regular Expressions6:06
    The "." wildcard in Perl is the most useful wildcard and can stand for any letter or symbol. Even if you only learn this one regular expression special character, you'll be able to do a whole lot more than if you didn't know it.
  • Groups: Finding Out What You Actually Matched6:58
    Groups are just a way of finding out what your regular expression wildcards actually matched. Which can be very handy.
  • Quantifiers: Greedy vs. Non-Greedy10:09
    Quantifiers enable you to say how many of a given character or wildcard you want to match. They can either match as much as possible, or just enough to gel with the rest of your regular expression.
  • Escape Sequences14:42
    Escape sequences let you match particular special characters or entire classes of characters, like all numbers or all alphanumeric characters and so on.
  • Numeric Quantifiers9:26
    Numeric quantifiers let you specify exactly how many of a given character or sequence you want to match. You can even specify a range.
  • Test Your Perl and Regex Knowlege - First Test25:02
    It's time for a test of your regex and Perl knowledge. Watch out -- there's a trick question near the end. It's so tricky, I even tricked myself.

Requirements

  • Basic knowledge of computer programming in any language.

Description

Discover some of the amazing things you can do with Perl 5, including downloading text and images from the Internet (just like Zuckerberg in The Social Network), reformatting data, importing and exporting data to and from databases, sysadmin-type tasks like renaming or moving files, fixing even huge amounts of data quickly and even creating web CGI scripts. In this course you'll also learn how to use regular expressions, those unbelievably useful little things that have now made their way into almost every serious programming language, yet remain the bête noire of many a developer.

Who this course is for:

  • Anyone who has some familiarity with basic programming in any language
  • Anyone who wants to learn how to automate common tasks in IT