Regular Expression Skipping Match

MRAB python at mrabarnett.plus.com
Sat Oct 2 18:15:21 CEST 2010


On 02/10/2010 04:13, AON LAZIO wrote:
> Hi python pals,
>     I need this help, say I have
>     h = "Hello \n World"
>     How would I create a regular expression that match only "Hello
> World"?  (ignore \n in the middle)
>     Thanks in advance
>
\s matches any whitespace, so:

     Hello\s+World



More information about the Python-list mailing list