Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from sys import getsizeof as gs
- list1=[1]
- list2=list([1])
- list1==list2 #true
- gs(list1) #80. (I guess 72 overhead +8 of the int)
- gs(list2) #104. (I guess 72 + 8 as above + 24 of...?)
- list3=[1,2,3,4,5]
- list4=list(list3)
- gs(list3) #112
- gs(list4) #136
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement