am I stupid

Fredrik Lundh effbot at telia.com
Tue May 23 12:33:42 EDT 2000


John Carter <jnc at ecs.soton.ac.uk> wrote:
> How do I put a backslash as the last character in a raw string.

read the fine FAQ ;-)

    http://www.python.org/doc/FAQ.html#6.29
    Why can't raw strings (r-strings) end with a backslash?

(summary: raw strings are parsed exactly as standard strings,
it's just that instead of translating escape sequences to character
codes, they're stored as is in the output string.  the faq entry
shows you some ways to get around this little problem...)

</F>

<!-- (the eff-bot guide to) the standard python library:
http://www.pythonware.com/people/fredrik/librarybook.htm
-->




More information about the Python-list mailing list