|
|
|
@ -96,8 +96,9 @@ special nature. |
|
|
|
|
|
|
|
You can match the characters not listed within the class by :dfn:`complementing` |
|
|
|
the set. This is indicated by including a ``'^'`` as the first character of the |
|
|
|
class; ``'^'`` outside a character class will simply match the ``'^'`` |
|
|
|
character. For example, ``[^5]`` will match any character except ``'5'``. |
|
|
|
class. For example, ``[^5]`` will match any character except ``'5'``. If the |
|
|
|
caret appears elsewhere in a character class, it does not have special meaning. |
|
|
|
For example: ``[5^]`` will match either a ``'5'`` or a ``'^'``. |
|
|
|
|
|
|
|
Perhaps the most important metacharacter is the backslash, ``\``. As in Python |
|
|
|
string literals, the backslash can be followed by various characters to signal |
|
|
|
|