What is Python? 5
This test assesses understanding of the tested concepts and skills. It evaluates the ability to apply information and analyze critically.
Sample Questions
Which Python feature allows a function to remember values between calls without using global variables?
- Closures
- Generators
- Decorators
- List comprehensions
What is the primary purpose of Python's Global Interpreter Lock (GIL)?
- To optimize garbage collection
- To synchronize thread execution
- To manage import statements
- To prevent memory leaks
In Python's descriptor protocol, which method is called when the attribute is accessed?
- __call__
- __delete__
- __get__
- __set__