Workshop

The workshop provides quiz questions to help you solidify your understanding of the material covered and exercises to give you experience in using what you've learned. Try and understand the quiz and exercise answers before you go on to tomorrow's lesson.

Quiz

1:Define the terms pattern matching and regular expressions.
A1: pattern matching is the concept on Perl of writing a pattern which is then applied to a string or a set of data. Regular expressions are the language you use to write patterns.
2:What sort of tasks is pattern matching useful for? Name three.
A2: There are many uses of pattern matching—you are limited only by your imagination. A few of them include

a. Input validation

b. Counting the number of things in a string

c. ...

Get Sams Teach Yourself Perl in 21 Days, Second Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.