regex that is equivalent to perl's syntax

Marc 'BlackJack' Rintsch bj_666 at
Mon Nov 12 16:49:00 CET 2007

On Mon, 12 Nov 2007 07:38:57 -0800, Lee Sander wrote:

> does python's re library have a similar capability of the perls
> regular expression to
> search for pattern that appears a variable number of times within the
> lower and upper bounds given? For example, what is the python's
> equivalent to the following perl's search string?
> m/^\S{1,8}\.\S{0,3}/

It is ``re.match(r'\S{1,8}\.\S{0,3}', string)``.  There's something called

	Marc 'BlackJack' Rintsch

More information about the Python-list mailing list