@author jackzhenguo
@desc
@date 2019/3/4
getsizeof
查看变量占用字节数
看到:字典比列表占用更多空间
In [1]: import sys
In [3]: a = [('a',1),('b',2)]
In [5]: sys.getsizeof(a)
Out[5]: 88
In [6]: a = {'a':1,'b':2.0}
In [7]: sys.getsizeof(a)
Out[7]: 248