Regular Expressions Flashcards

1
Q

*

A

0 or more

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

+

A

1 or more

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

?

A

0 or 1

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q
A

beginning of string

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

$

A

end of string

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

.

A

any character (except newline)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

\b

A

word boundary (beginning and end), includes punctuation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

\B

A

within a word

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

^\d{4}

A

sequence of exactly 4 digits

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

\d

A

digit

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

\D

A

non-digit

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

\s

A

whitespace character

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

\S

A

non-whitespace character

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

\w

A

alphanumeric or underscore [a-zA-Z0-9_]

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

( | )

) | (

A

or

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

[ ] [ ]

A

and