© William "Bo" Rothwell of One Course Source, Inc. 2019
William "Bo" RothwellBeginning Perl Programminghttps://doi.org/10.1007/978-1-4842-5055-6_9

9. Pattern Matching

William “Bo” Rothwell1 
(1)
San Diego, CA, USA
 

Pattern Matching vs. Wildcards

Operating systems use “wildcards” in order to make referring to filenames easier. The idea of regular expressions (or patterns) in Perl is very much like wildcards...at least conceptually. While wildcards are special characters that refer to filenames, regular expressions are special characters that refer to text within a string.

While most operating systems only have a few wildcards, Perl has many regular expressions (see the “Modifiers” section). In this manual, for brevity, a regular expression is often referred ...

Get Beginning Perl Programming: From Novice to Professional now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.