2021-06-17
阅读量:
603
提问:for为什么报错
----
不能对数值型本身进行遍历,如 for i in 3.1413,打印i会报错,这里可以修改成:
a=0 for i in vegetable_price: a+=vegetable_price[i]['high']






评论(0)


暂无数据
推荐帖子
0条评论
0条评论
1条评论