小编ɐud*_*s s的帖子

dumps() 需要 1 个位置参数,但给出了 2 个

import json
a={"name": "abc", "age": 20, "sal": 20000}
with open("test.json", "w") as p1:
    json.dumps(a, p1)
Run Code Online (Sandbox Code Playgroud)

下面是错误
dumps()需要 1 个位置参数,但给出了 2 个

Python 版本:3.6.4

json python-3.x

1
推荐指数
1
解决办法
4982
查看次数

标签 统计

json ×1

python-3.x ×1