[Tutor] convert '\\t' to '\t'
Aurelio Magalhaes Dias
amd@atlas.ucpel.tche.br
Thu Jan 16 11:56:01 2003
I think what he wants is like:
>>> text =3D "something\\nto print"
>>> text =3D text.replace('\\n','\n')
>>> print text
something
to print
-----------------------------------------
Aur=E9lio Magalh=E3es Dias
Ci=EAncia da Computa=E7=E3o
UCPel - RS - Brasil
-----------------------------------------
> are you saying you want to go from printing 'backslash n' to printing a
> newline (and the equivalent for the other items)? Or are you saying to w=
ant
> to go from 'backslash backslash n' to 'backslash n' and not get a newline=
(or
> equivalent).
>
> If the list understands exactly what you we can help you get there. Perh=
aps
> an example of actual usage would be helpful to all rather than being bogg=
ed
> down in "how many slashes do you want".
>