Two Python lists of the same size can take different amounts of memory, even if they contain exactly the same elements. A larger list can even take less memory than a smaller list. How can this be? Lists appear to remember more than just their elements, and somehow contain some information of their history. In this video we investigate this phenomenon. We see what the system getsizeof function returns and how the internal structure of a list is represented in order to find the answer.
― mCoding with James Murphy ()
Source code:
libcst:
AST linting vid:
Structural pattern matching vid:
SUPPORT ME ⭐
---------------------------------------------------
Sign up on Patreon to get your donor role and early access to videos!
Feeling generous but don’t have a Patreon? Donate via PayPal! (No sign up needed.)
https://
1 view
13
2
2 months ago 05:31:30 2
Python Tutorial for Beginners - Learn Python in 5 Hours [FULL COURSE]
2 months ago 00:26:52 1
Кибергулаг: от электронных повесток до слежки в Сети | ВПН, Госуслуги и видеонаблюдение
2 months ago 15:41:56 1
Python - Полный Курс по Python [15 ЧАСОВ]
3 months ago 00:12:37 1
LEGB-rule. Как Python ищет имена переменных
4 months ago 05:27:42 1
Python — полный курс для начинающих. Этот навык изменит твою жизнь.
4 months ago 00:02:44 1
How Florida biologists discovered a Burmese python swallowing a fully-grown deer
4 months ago 03:39:43 1
Полный курс Sqlite - работа с базами данных SQL для новичков
4 months ago 00:02:12 1
The Beatles - Eleanor Rigby (From “Yellow Submarine“)