1
Variables in Python act as 'tags' pointing to objects (boxes containing values) in memory rather than being storage boxes themselves.
2
The id() function is used to find the memory address of an object or variable.
3
Python is memory efficient: if multiple variables are assigned the exact same value/data, they will point to the same memory object (sharing the same id).
4
When a variable's value is changed, it is reassigned to point to a new object with a different memory address.
5
Python has a built-in garbage collection mechanism that automatically cleans up objects in memory that no longer have any variable references (tags) pointing to them.
6
Python does not have a strict language-level mechanism to enforce constants, but developers use all-caps naming conventions (e.g., PI = 3.14) to signal that a variable should be treated as a constant.
7
The type() function is used to check the data type of a variable or object (e.g., int, float).