Memory diagram of a Python list

1. Features of the list

1. List elements are sorted in order
2. Index maps unique data
3. The list can store repeated data
4. Mixed storage of any data type
5. Dynamically allocate and reclaim memory as needed

Second, the memory diagram of the list

lst=['hello','world',66]

insert image description here

Guess you like

Origin blog.csdn.net/fancynthia/article/details/129817733