Groups and Ranges Flashcards
1
Q
.
A
Any character except new line (\n)
2
Q
(a|b)
A
a or b
3
Q
(…)
A
Group
4
Q
(?:…)
A
Passive (or non-capturing) group
5
Q
[abc]
A
Range (a or b or c)
6
Q
[^abc]
A
Not a or b or c
7
Q
[a-z]
A
Lower case letter between a and z
8
Q
[A-Z]
A
Upper case letter between A and Z
9
Q
[0-7]
A
Digit between 0 and 7
10
Q
\n
A
nth group/subpattern