[pyar] [OT] - Checkeando parentesis balanceados.

John Rowland Lenton john.lenton en canonical.com
Vie Jun 18 19:24:34 ART 2010


On Fri, Jun 18, 2010 at 07:22:15PM -0300, Roberto Alsina wrote:
> On Friday 18 June 2010 18:49:15 John Rowland Lenton wrote:
> > $ python -m timeit -s 'from q import f_eval, f_re' 'f_re("("*100 +
> > ")"*100)' 1000 loops, best of 3: 1.72 msec per loop
> > $ python -m timeit -s 'from q import f_eval, f_re' 'f_eval("("*100 +
> > ")"*100)'
> 
> Si, pero re.compile falla a los 101, vivaracho :-D

hacele .replace("(", "(?:") entonces :)
------------ próxima parte ------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 490 bytes
Desc: Digital signature
URL: <http://listas.python.org.ar/pipermail/pyar/attachments/20100618/4683c7d3/attachment.sig>


More information about the pyar mailing list