Why the size of set can be bigger than dict in python?

前端 未结 0 1912
醉梦人生
醉梦人生 2020-12-30 01:59

Why is the size of a set bigger than that of a dict?

s = set()
d = {}

for i in range(20):
    s.add(i)
    d[i] = 1

    print(f\'{         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题