On 10/16/07, Massimo Di Pierro <[EMAIL PROTECTED]> wrote: > Even stranger > > >>> re.sub('a', '\\n','bab') > 'b\nb' > >>> print re.sub('a', '\\n','bab') > b > b >
You called print, so instead of getting an escaped string literal, the string is being printed to your terminal, which is printing the newline. -- http://mail.python.org/mailman/listinfo/python-list