Quiz: Python Metaclasses
Interactive Quiz ⋅ 8 Questions
By Joseph Peart
In this quiz, you’ll test your understanding of
Python Metaclasses.
Metaclasses sit behind every class you write in Python, and they’re one of the language’s deeper object-oriented concepts. By working through this quiz, you’ll revisit how classes are themselves objects, how type creates them, and how a custom metaclass lets you customize class creation.
You’ll also reflect on when a custom metaclass is actually the right tool and when a simpler technique does the job better.