re — Regular expression operations — Python 3.15.2 documentation
A regular expression (or RE) specifies a set of strings that matches it; the functions in this module let you check if a particular string matches a given ...
A regular expression (or RE) specifies a set of strings that matches it; the functions in this module let you check if a particular string matches a given ...
Source code: Lib/string/__init__.py String constants: The constants defined in this module are: Custom string formatting: The built-in string class provides ...
'\' ) to indicate special forms or to allow special characters to be used without invoking their special meaning. · '\\\\' as the pattern string, because the ...
Regular expressions will often be written in Python code using this raw string notation.Split the string into a list, splitting it wherever the RE matches. sub(). Find all substrings where the RE matches, and replace them with a different string.
Regular expressions will often be written in Python code using this raw string notation.If *replacement* is a function, the function is called for every non-overlapping occurrence of *pattern*.
Return the string representing a character with the specified Unicode code point. For example, chr(97) returns the string 'a' , while chr(8364) ...
... expression list (which may be a single expression). In interactive ... string is unaffected by global statements in the code containing the function call.