python将字符串转换为字典

a=’{“state”:100}’
b=json.loads(a)
print(b[‘state’])

猜你喜欢

转载自blog.csdn.net/fnms88/article/details/83106503