LernerPython

Advanced objects

Go beyond the basics of object-oriented Python. Understand how the object system is implemented under the hood, and how to use that knowledge for cleaner, more idiomatic, more efficient code.

What you should know

Course Content

Course length

8 hours

Number of lessons

75

Training materials

14 PDFs + notebooks

Coding exercises

19

LEARN MORE

Compared with many other languages, Python’s object-oriented facilities are quite straightforward and simple. Once you understand classes, instances, attributes, and methods, you’ve basically learned everything you need, right?

Maybe, if you have simple needs. But if you want to build complex object-oriented systems, or just want to really understand what Python is doing when it works with objects, then you’ll need to go deeper, looking at such topics as magic methods, inheritance, descriptors, and metaclasses. Even if you don’t use these techniques in your programs, they’ll help you to see the consistency and elegance in Python’s implementation. You’ll understand error messages that come up, and traps that people fall into.

Python’s objects are just as capable as those in other languages, but it takes some time to understand just how those capabilities are implemented, and how to take advantage of them. In this course, you’ll uncover all of the secrets of object-oriented Python, and come out a better, more sophisticated coder.

This is the deepest and more complete course you’ll find on object-oriented Python, and will give you the insights you need to use objects to their greatest potential.

  • Advanced magic methods
  • Operator overloading
  • Multiple inheritance
  • __new__ (vs.__init__)
  • Descriptors
  • Metaclasses

This course, like all others on LernerPython, is taught by Reuven Lerner.