Why does Python output a string and a unicode of the same value differently?
- by Thierry Lam
I'm using Python 2.6.5 and when I run the following in the Python shell, I get:
>>> print u'Andr\xc3\xa9'
André
>>> print 'Andr\xc3\xa9'
André
>>>
What's the explanation for the above? Given u'Andr\xc3\xa9', how can I display the above value properly in an html page so that it shows André instead of André?