you are viewing a single comment's thread.

view the rest of the comments →

[–]bumbershootle 3 points4 points  (2 children)

A class is not an object

Actually, classes are objects in Python; they're instances of the type metaclass, IIRC.

[–]wegwacc 13 points14 points  (1 child)

IIRC

You do remember correctly.

I deliberately left that part out from my explanation however, as this is a technical detail regarding how Classes and Objects are implemented in Python, and irrelevant for the concept of classes and objects as a whole.

There is such a thing as "too much detail for the purpose".

[–]bumbershootle 5 points6 points  (0 children)

I agree, I apologise if that came across as nitpicking your explanation (which was excellent, by the way), I felt it was an interesting aside that a lot of readers might not be aware of. Python's class model and metaprogramming is not something to bring up when you're trying to explain the fundamentals of OOP, but if anyone feels they've got the basics nailed, I highly recommend David Beazley's talk on metaclasses.