Python Professional — Hard
Key points
- @staticmethod is inherited by subclasses
- Module-level functions are independent of classes
- @staticmethod is used for logic related to a specific class
- Module functions are preferred for logic independent of any class
Ready to go further?
Related questions
