python里面出现中文的时候报错 'ascii' codec can't encode characters in position

编码问题,在头部添加

import sys
reload(sys)
sys.setdefaultencoding( "utf-8" )

  

 

http://www.xuebuyuan.com/2226637.html

posted @ 2016-06-17 00:33  juandx  阅读(2381)  评论(0编辑  收藏  举报