[Tutor] Printing RAW string
Kaustubh Pratap chand
Warrior at programmer.net
Fri Jun 10 22:57:23 CEST 2011
How i can print the string in raw...as it is
s="hello world\n"
print s
Output:
helloworld
But i want it to be "hello world\n"
I know it can be done by adding a 'r' prefix but is there any other way because the string will be taken in during input!
Any help appreciated :D
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20110610/89d52cec/attachment.html>
More information about the Tutor
mailing list