[Tutor] Regex across multiple lines

Kent Johnson kent37 at tds.net
Wed Apr 26 15:33:41 CEST 2006

Liam Clarke wrote:

> To the Tutor list - can't re.MULTILINE also be used? I've never really
> used that flag.

re.MULTILINE affects the meaning of ^ and $ - do they match only the 
beginning and end of the target string (the default) or do they match 
the beginning or end of any line in the string.

re.DOTALL affects the meaning of . - does it match newlines or not?

The docs on these flags are pretty clear, take a look.


More information about the Tutor mailing list