Python Regulare Expression - Printable Version +- Python Forum (https://python-forum.io) +-- Forum: Python Coding (https://python-forum.io/forum-7.html) +--- Forum: Data Science (https://python-forum.io/forum-44.html) +--- Thread: Python Regulare Expression (/thread-40281.html) |
Python Regulare Expression - stahorse - Jul-04-2023 I have this code here and I want to know how to interpret it: found = re.findall( r'encoding="UTF-8"\?>(.*?)^<\?xml version="1.0"', clean, re.M | re.S, )I can see where "Clean" comes from, but not sure what is "re.M" and "re.S". Can I please get an explanation of the whole syntax. RE: Python Regulare Expression - buran - Jul-04-2023 The docs: https://docs.python.org/3/library/re.html#re.M https://docs.python.org/3/library/re.html#re.S |