[Tutor] Regexp Not Matching on Numbers?

Kent Johnson kent37 at tds.net
Tue Dec 14 19:16:32 CET 2004


Max Noel wrote:
> On Dec 14, 2004, at 18:15, Gooch, John wrote:
>> So far I have tried the following regular
>> expressions:
>> "\d+"
>> "\d*"
>> "\W+"
>> "\W*"
>> "[1-9]+"
>> and more...
> 
> 
>     I think you have to escape the backslashes.

or use raw strings like r"\d+" which is what is in the sample code...

Kent


More information about the Tutor mailing list