Why self?

Jesper Olsen jolsen at mailme.dk
Fri Jul 5 05:36:25 EDT 2002


Why is it necessary to use a "self" argument to class methods in python?

To me it seems a bit like doing object oriented programming in C...

Why not make it implicit like "this" in C++?

I do not find it usefull that I can give it my own name.

So, is it just legacy or is there a reason for this convention?

Cheers
Jesper



More information about the Python-list mailing list