June 2017
Beginner to intermediate
274 pages
6h 49m
English
First of all, we can run code before the code inside the class block is evaluated for each class, which is an instance of the metaclass. We do this by having the metaclass set as a __prepare__ method, which should be a class method or a static method because it will be called before the instance is created.
Read now
Unlock full access