Python 2.7.13变量加重

时间:2017-09-14 00:16:23

标签: python python-2.7

Ubuntu 17.04 x64
Python 2.7.13

我很难尝试使用重音调用变量:

└──╼ $python
Python 2.7.13 (default, Jan 19 2017, 14:48:08) 
[GCC 6.3.0 20170118] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> nomes = ('Mário')
>>> nomes
'M\xc3\xa1rio'
>>> 

任何提示? :)

此致 Vitor Jr。

1 个答案:

答案 0 :(得分:1)

尝试print nomes,你会发现它有你想要的东西。

您看到的'M\xc3\xa1rio就是Python如何表示特殊字符。