[Tutor] Newbie - regex question

Marc Tompkins marc.tompkins at gmail.com
Tue Aug 31 00:16:35 CEST 2010


On Mon, Aug 30, 2010 at 2:56 PM, Hugo Arts <hugo.yoshi at gmail.com> wrote:

> To solve, we have the non-greedy patterns. They eat not as much
> possible, but as little as possible. To make a qualifier non-greedy,
> simply add an asterix at its end:
>
> r'<email>WORD1-.*?</email>'
>
> I would also like to offer one small correction: an asterisk may be greedy,
but Asterix is a cheerful, brave Gaul.


-- 
www.fsrtechnologies.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20100830/c5b09ca4/attachment.html>


More information about the Tutor mailing list