Why is the memory allocation for a list x numbers less than the memory allocation of its combined elements? intA is an integer value of 10, requiring 28bytes for storage. However, List A contains 10 integers and requires 184bytes? What is the reasoning for this? I would have suspected the memory allocation would be greater that 10 times the bytes requires for a single integer, considering the list data structure is also required to be stored in memory, in addition to the pointers and lastly their integer object values. Unless it describes the memory allocation for the List structure only. Any clarifications? Thanks
intA = 10
A = [x for x in range(0,10)]
print(getsizeof(intA), getsizeof(A))
Output: 28 184