Regular Expressions in Perl
1. It is a wildcard and can match any single character, except for line breaks. If you want to use. In the mode, use /.
2. * match the first item zero or multiple times, such as/AB * C/match AC, ABC, abbbbbc...
3. + can match the previous item once or any number of times, such as/AB + C/, matching ABC, abbc, abbbbc...
4 .? This indicates that the previous item appears once or does not appear, for example,/AB? C/, matching ABC, or AC
5. () is used for grouping, such as/(AB) + C/, matching ABC, ababc, abababc; or/(AB) * C/, matching any string ending with C
6. | indicates matching the left or right, that is, if the Left is not matched, the right is matched, for example,/AB | C/, matching AB or C
7. [] can match any single character in the brackets, such as [ABC], matching a, B, c
8.-The font size can be used in []. For example, [a-c] is the same as the preceding example.
9. ^ used in [] to obtain the complement, for example, [^ d-Z], matching [ABC]
10. Any numeric class, [0-9], can be abbreviated as:/d
11./W is called "word" character: [A-Za-z0-9 _]
12./s indicates [/f/n/T/R]. "In fact, it is rare to use/s separately without using any quantifiers (*, + )"
13. /d,/W,/s, will match the characters corresponding to them in lower-case form that cannot match, equivalent to [^/d], [^/W], [^/S]
14. [/D/d] is usually used to match any character