وظائف Python RegEx
وظائف RegEx
تقدم re
الوحدة مجموعة من الوظائف التي تسمح لنا بالبحث في سلسلة عن تطابق:
Function | Description |
---|---|
findall | Returns a list containing all matches |
search | Returns a Match object if there is a match anywhere in the string |
split | Returns a list where the string has been split at each match |
sub | Replaces one or many matches with a string |