Alex Martelli <aleax at aleax.it> -> search re and put in a list??
aleax at aleax.it
Mon Sep 16 22:13:44 CEST 2002
jubafre at brturbo.com wrote:
> Traceback (most recent call last):
> File "<string>", line 1, in ?
> File "C:\Documents and Settings\jubafre\Desktop\teste.py", line 27, in ?
> final = [ big_re.sub(x, replacer)for x in S ]
> TypeError: expected string or buffer
> what happened????
Exchange the arguments to big_re.sub -- it's
final = [ big_re.sub(replacer, x) for x in S ]
More information about the Python-list