Python Flashcards
What modules/libraries are you most familiar with? What do you like or dislike about them?
Answer
In Python, how is memory managed?
In Python, memory is managed in a private heap space. This means that all the objects and data structures will be located in a private heap. However, the programmer won’t be allowed to access this heap. Instead, the Python interpreter will handle it. At the same time, the core API will enable access to some Python tools for the programmer to start coding. The memory manager will allocate the heap space for the Python objects while the inbuilt garbage collector will recycle all the memory that’s not being used to boost available heap space
What are the supported data types in Python?
“Python’s built-in (or standard) data types can be grouped into several classes. Sticking to the hierarchy scheme used in the official Python documentation these are numeric types, sequences, sets and mappings.”
What is the difference between a tuple and a list in Python?
“Apart from tuples being immutable there is also a semantic distinction that should guide their usage.”