In this lesson, you’ll learn how to use RegEx (regular expressions) to work with sets of characters. Unlike the
., which matches any single character , sets enable you to match specific characters and character ranges.
Matching one of several characters
As you learned in the previous lesson,
. matches any one character (as does any literal character). In the final example in that lesson,
.a was used to match both
. matched both the
s. But what if there was a file (containing Canadian sales data) named ca1.xls as well, and you still wanted to match only
. would also match
c, and so that filename would also be matched.