笔记:
python的字典转换为中文输出:
#coding:utf-8
import json
dic = {'张三':2,'李四':3,'王五':5}
print json.dumps(dic,encoding='utf-8',ensure_ascii=False)
笔记:
python的字典转换为中文输出:
#coding:utf-8
import json
dic = {'张三':2,'李四':3,'王五':5}
print json.dumps(dic,encoding='utf-8',ensure_ascii=False)