[Python-au] String Casting
sjmachin at lexicon.net
sjmachin at lexicon.net
Fri Mar 25 02:57:51 CET 2005
On 25 Mar 2005 at 10:41, Bryce Macdonald wrote:
>
> Hi
>
> I have a string that is posted to my python program (which I cant control) that contains the literal
> r\x7E\x0D\x0A and I want it to convert it to equal ~\r\n
>
> Is there a way to convert this string ?
>
1. What do you mean, "posted to"?
2. You can't control your Python program?
3. Given the following, why do you want to convert it?
>>> '\x7E\x0D\x0A' is '~\r\n'
True
>>>
More information about the python-au
mailing list