@@ -230,58 +230,58 @@ False
230230
231231| Meta characters | Description |
232232| ------------- | ----------- |
233- | ^ | anchor, match from beginning of string |
234- | $ | anchor, match end of string |
235- | . | Match any character except newline character \n |
233+ | ` ^ ` | anchor, match from beginning of string |
234+ | ` $ ` | anchor, match end of string |
235+ | ` . ` | Match any character except newline character ` \n ` |
236236| | ; | OR operator for matching multiple patterns |
237- | () | for grouping patterns and also extraction |
238- | [ ] | Character class - match one character among many |
239- | &# 92 ; ^ | use \ to match meta characters like ^ |
237+ | ` () ` | for grouping patterns and also extraction |
238+ | ` [] ` | Character class - match one character among many |
239+ | ` \^ ` | prefix ` \ ` to match meta characters like ` ^ ` |
240240
241241<br >
242242
243243| Quantifiers | Description |
244244| ------------- | ----------- |
245- | * | Match zero or more times the preceding character |
246- | + | Match one or more times the preceding character |
247- | ? | Match zero or one times the preceding character |
248- | {n} | Match exactly n times |
249- | {n,} | Match at least n times |
250- | {n,m} | Match at least n times but not more than m times |
245+ | ` * ` | Match zero or more times the preceding character |
246+ | ` + ` | Match one or more times the preceding character |
247+ | ` ? ` | Match zero or one times the preceding character |
248+ | ` {n} ` | Match exactly n times |
249+ | ` {n,} ` | Match at least n times |
250+ | ` {n,m} ` | Match at least n times but not more than m times |
251251
252252<br >
253253
254254| Character classes | Description |
255255| ------------- | ----------- |
256- | [ aeiou] | Match any vowel |
257- | \ [ ^aeiou] | ^ inverts selection, so this matches any consonant |
258- | [ a-f] | Match any of abcdef character |
259- | \d | Match a digit, same as [ 0-9] |
260- | \D | Match non-digit, same as \ [ ^0-9] or \ [ ^\d] |
261- | \w | Match alphanumeric and underscore character, same as [ a-zA-Z _ ] |
262- | \W | Match non-alphanumeric and underscore character, same as \ [ ^a-zA-Z _ ] or \ [ ^\w] |
263- | \s | Match white-space character, same as [ \ \t\n\r\f\v] |
264- | \S | Match non white-space character, same as \ [ ^\s] |
265- | \b | word boundary, word defined as sequence of alphanumeric characters |
266- | \B | not a word boundary |
256+ | ` [aeiou] ` | Match any vowel |
257+ | ` [^aeiou] ` | ` ^ ` inverts selection, so this matches any consonant |
258+ | ` [a-f] ` | Match any of abcdef character |
259+ | ` \d ` | Match a digit, same as ` [0-9] ` |
260+ | ` \D ` | Match non-digit, same as ` [^0-9] ` or ` [^\d] ` |
261+ | ` \w ` | Match alphanumeric and underscore character, same as ` [a-zA-Z0-9_] ` |
262+ | ` \W ` | Match non-alphanumeric and underscore character, same as ` [^a-zA-Z0-9_] ` or ` [^\w] ` |
263+ | ` \s ` | Match white-space character, same as ` [\ \t\n\r\f\v] ` |
264+ | ` \S ` | Match non white-space character, same as ` [^\s] ` |
265+ | ` \b ` | word boundary, see ` \w ` for characters constituting a word |
266+ | ` \B ` | not a word boundary |
267267
268268<br >
269269
270270| Compilation Flags | Description |
271271| ------------- | ----------- |
272- | re.I | ignore case |
273- | re.M | multiline mode, ^ and $ anchors work on internal lines |
274- | re.S | singleline mode, . will also match \n |
275- | re.V | verbose mode, for better readability and adding comments |
272+ | ` re.I ` | ignore case |
273+ | ` re.M ` | multiline mode, ` ^ ` and ` $ ` anchors work on internal lines |
274+ | ` re.S ` | singleline mode, ` . ` will also match ` \n ` |
275+ | ` re.V ` | verbose mode, for better readability and adding comments |
276276
277277* [ Python docs - Compilation Flags] ( https://docs.python.org/3/howto/regex.html#compilation-flags ) - for more details and long names for flags
278278
279279<br >
280280
281281| Variable | Description |
282282| ------------- | ----------- |
283- | \1, \2, \3 etc | backreferencing matched patterns |
284- | \g<1>, \g<2>, \g<3> etc | backreferencing matched patterns, useful to differentiate numbers and backreferencing |
283+ | ` \1 ` , ` \2 ` , ` \3 ` etc | backreferencing matched patterns |
284+ | ` \g<1> ` , ` \g<2> ` , ` \g<3> ` etc | backreferencing matched patterns, useful to differentiate numbers and backreferencing |
285285
286286<br >
287287
0 commit comments