header START About Software Disclaimers Resume – Recruiters Please Read Portfolio Itches Elf Sternberg Done, and gets things smart. Search header END container START Side Central START Start Post 06 Jul Posted by Elf Sternberg as programming , python So, while working my way through my current project, I came across the notion of a ‘slot’ as discussed here . And I wondered, what the Hell is a slot? A slot is nothing more than a memory management nicety: when you define __slots__ on a class, you’re telling the Python interpreter that the list of attributes described within are the only attributes this class will ever need, and a dynamic dictionary is not needed to manage the references to other objects within the class. This can save enormous amounts of space if you have thousands or millions of objects in memory. For example, if you define: class...