Hi,

>     for punctuation in punctuations:
>         line=line.replace(punctuation,'')
I would use maketrans or even a regex instead. However, If you care
about speed, it is well known that in some cases regex take more
time than multiple replaces. Even the maketrans could take more time
(I don't know; you may benchmark it -> homework)

Regards,
Josef

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to