python json
来源:互联网 发布:淘宝企业店铺出售过程 编辑:程序博客网 时间:2024/04/28 12:38
转自 http://blog.chinaunix.net/uid-9525959-id-3074355.html
#!/usr/bin/pythonimport json#Function:Analyze json script#Json is a script can descript data structure as xml, #for detail, please refer to "http://json.org/json-zh.html".#Note:#1.Also, if you write json script from python,#you should use dump instead of load. pleaser refer to "help(json)".#json file:#The file content of temp.json is:#{# "name":"00_sample_case1",# "description":"an example."#}#f = file("temp.json");#s = json.load(f)#print s#f.close#json string:s = json.loads('{"name":"test", "type":{"name":"seq", "parameter":["1", "2"]}}')print sprint s.keys()print s["name"]print s["type"]["name"]print s["type"]["parameter"][1]
0 0
- python json
- [python]json
- Python - Json
- python-json
- python json
- Python JSON
- python Json
- python json
- python json
- Python JSON
- python Json
- Python JSON
- Python & JSON
- Python json
- python json
- Python JSON
- Python JSON
- Python-json
- C#,xml、html节点数据解析
- 中缀表达式转后缀表达式
- CTF
- Linux硬链接与软链接
- online_judge_1037
- python json
- C 函数调用 递归 斐波那契
- malloc函数的使用
- docker如何简单部署mysql
- ubuntu里面的任务管理器
- JS开发者调查
- Installing Theano
- 可米网络电话 核心分析
- MySql避免重复插入记录