?
What is the purpose of the __slots__ attribute in Python classes?
Answer & Solution
Correct Answer:
Option
B
The __slots__ attribute restricts the attributes that can be added to instances, optimizing memory usage.
Join the Discussion
Login to post a comment or share your explanation.
Login