Congratulations! You now know how to use classes for object-oriented programming (OOP) in Python. Specifically, you can:
- Compose classes together
- Inherit and override behavior from other classes
- Creatively mix and match these approaches
With these skills to your name, you’re now ready to tackle creating complex systems and writing sleek, Pythonic code.
To reinforce what you’ve learned here, complete the quiz in the next lesson. Then, head over to Python Basics Exercises: Building Systems With Classes.
Then, keep growing your skill set as a programmer by continuing with the other Python Basics courses and getting yourself a copy of Python Basics: A Practical Introduction to Python 3.
You can also check out these Real Python video courses:
- Inheritance and Composition: A Python OOP Guide
- Supercharge Your Classes With Python
super()
- Using Data Classes in Python
- Managing Attributes With Python’s property()
- Providing Multiple Constructors in Your Python Classes
If you’d prefer to read, then these written tutorials are for you:
- Inheritance and Composition: A Python OOP Guide
- Supercharge Your Classes With Python
super()
- Data Classes in Python 3.7+ (Guide)
- Python’s
property()
: Add Managed Attributes to Your Classes - Providing Multiple Constructors in Your Python Classes
Congratulations, you made it to the end of the course! What’s your #1 takeaway or favorite thing you learned? How are you going to put your newfound skills to use? Leave a comment in the discussion section and let us know.