RegEx Quick Flashcards

1
Q

Name the 11 metacharacters

A

^ $ | \ () {} [] ? . * +

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

What do each of the 11 metacharacters do

A
  • hat (signifies beginning)
  • signifies the end
  • quantifier
  • explicitly states single characters
  • states the order of things
  • represents all things
  • makes characters literal
  • OR
  • zero or one
  • zero or more
  • one or many of previous expression
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Difference between [aeiou] and [^aeiou]

A

One expression extracts any single element in a document that matches any single one of our given characters.

The other expression finds characters that do NOT match a single character in our pattern.

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

What is the acronym that represents 12 different character escapes?

A

BratS fenD pwv
(people.with.cute.v)

\b \r \a \t sS
\f \e \n dD
pP wW cC v

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

What are the three escaping characters that use numbers?

A

\x20
\040
\u0020

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

What do the 3 escaping characters with numbers mean?

A

-

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

What are hyphens and what is a range.

A

(-) link together a hexadecimal range of options.
These two things are the same:
(abc) and (a-c). The range of characters is a through c.

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