1. #coding=utf-8
2. import sys
reload(sys)
sys.setdefaultencoding("utf-8")
3. str unicode 编码,参考链接:https://www.jb51.net/article/133452.htm
4. unicode("中国")
5. 和.py 文件本身的编码有关 https://blog.csdn.net/Islotus/article/details/71147474
1. #coding=utf-8
2. import sys
reload(sys)
sys.setdefaultencoding("utf-8")
3. str unicode 编码,参考链接:https://www.jb51.net/article/133452.htm
4. unicode("中国")
5. 和.py 文件本身的编码有关 https://blog.csdn.net/Islotus/article/details/71147474