diff --git a/Doc/howto/regex.rst b/Doc/howto/regex.rst index e9404a4a7f88e9..1164be0f338686 100644 --- a/Doc/howto/regex.rst +++ b/Doc/howto/regex.rst @@ -996,7 +996,7 @@ desired group's name. Named groups are still given numbers, so you can retrieve information about a group in two ways:: >>> p = re.compile(r'(?P\b\w+\b)') - >>> m = p.search( '((( Lots of punctuation )))' ) + >>> m = p.search('((( Lots of punctuation )))') >>> m.group('word') 'Lots' >>> m.group(1)