python3 字典嵌套字典 赋值异常解决及猜测
针对dict中 嵌套dict 出现复制异常:
lists={}
test=['s1','s2','s3']
data = {'value': '',}
for i in range(2):
lists[i]=data
# dic = {0: {'value': '',}, 1:{'value': '',}}
for j in range(2):
# print(j)
l...
原创
2018-10-31 17:11:37 ·
1629 阅读 ·
0 评论