How does a method of a subclass become a method of the base class?
Mats Wichmann
mats at wichmann.us
Mon Mar 27 10:08:44 EDT 2023
On 3/26/23 17:53, Jen Kris via Python-list wrote:
> I’m asking all these question because I have worked in a procedural style for many years, with class work limited to only simple classes, but now I’m studying classes in more depth. The three answers I have received today, including yours, have helped a lot.
Classes in Python don't work quite like they do in many other languages.
You may find a lightbulb if you listen to Raymond Hettinger talk about them:
https://dailytechvideo.com/raymond-hettinger-pythons-class-development-toolkit/
I'd also advise that benchmarks often do very strange things to set up
the scenario they're trying to test, a benchmark sure wouldn't be my
first place to look in learning a new piece of Python - I don't know if
it was the first place, but thought this was worth a mention.
More information about the Python-list
mailing list