摘要: Python读取文件中的字符串已经是unicode编码,如:\u53eb\u6211,需要转换成中文时有两种方式 1.使用eval: 2.使用decode: unicodestr.decode('unicode_escape') # 将转义字符\u读取出来 # ’\u’开头就基本表明是跟unicod 阅读全文
posted @ 2017-04-20 13:41 好奇的小明 阅读(29001) 评论(0) 推荐(1) 编辑