Regular Expressions

0.0(0)
studied byStudied by 0 people
0.0(0)
full-widthCall with Kai
GameKnowt Play
New
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/39

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

40 Terms

1
New cards

[]

Match single value in range that is listed inside the bracket.

2
New cards

-

Used as range separator. To search, must be first in list

3
New cards

^

Matches the starting position within the line

4
New cards

[^ ]

Matches a single character that is not contained within the brackets

5
New cards

$

Matches last character. Must be at end of the expression

6
New cards

.

Match any character in position

7
New cards

\d

Matches any single decimal digit; this is equivalent to the class [0-9].

8
New cards

\D

Matches any single non-digit character; this is equivalent to the class [^0-9].

9
New cards

\s

Matches any single whitespace character; this is equivalent to the class [\t\n\r\f\v].

10
New cards

\S

Matches any single non-whitespace character; this is equivalent to the class [^ \t\n\r\f\v].

11
New cards

\w

Matches any single alphanumeric character; this is equivalent to the class [a-zA-Z0-9_].

12
New cards

\W

Matches any single non-alphanumeric character; this is equivalent to the class [^a-zA-Z0-9_].

13
New cards

*

Match previous character 0 or more times (lo*se) 🡪 lse, loose, looose

14
New cards

+

Match previous character 1 or more times (lo+se) 🡪 lose, loose, loose

15
New cards

?

Match previous character 1 or 0 times (lo?se) 🡪 lse, lose

16
New cards

{X}

Match previous character exactly x times

17
New cards

{x,y}

Match at least x, but no more than y (ba{1,4}t) 🡪 bat, baat, baaat, baaaat

18
New cards

{x,}

Match at least x or more times

19
New cards

()

grouping, seperaed by |

20
New cards

(?:

Non capturing group

21
New cards

\

Escape

22
New cards

/

Delimiter

23
New cards

|

Alteration or logical OR

24
New cards

\<

Match beginning of word

25
New cards

\>

Match the end of the word

26
New cards

\n

New line

27
New cards

\r

Carriage return

28
New cards

\t

tab

29
New cards

[[:alnum:]]

Alphanumeric characters

30
New cards

[[:alpha:]]

Alphabetic characters

31
New cards

[[:blank:]]

Blank characters, such as space and tab

32
New cards

[[:cntrl:]]

Control characters. In ASCII, these characters have octal codes 000 - 037 and 177 (DEL)

33
New cards

[[:digit:]]

Digits: 0-9

34
New cards

[[:graph:]]

Graphical characters: '[[:alnum:]]' and '[[:punct:]]'

35
New cards

[[:lower:]]

lower-case letters

36
New cards

[[:print:]]

Printable characters: '[[:alnum:]]', '[[:punct:]]', and space

37
New cards

[[:punct:]]

Punctuation characters

38
New cards

[[:space:]]

Space characters, including tab, newline, vertical tab, form feed, carriage return, and space

39
New cards

[[:upper:]]

Upper-case letters

40
New cards

[[:xdigit:]]

Hexadecimal digits