Why self?

Erik Max Francis max at alcyone.com
Fri Jul 5 05:40:42 EDT 2002


Jesper Olsen wrote:

> 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++?

Explicit is better than implicit.

-- 
 Erik Max Francis / max at alcyone.com / http://www.alcyone.com/max/
 __ San Jose, CA, US / 37 20 N 121 53 W / ICQ16063900 / &tSftDotIotE
/  \ See the son in your bad day / Smell the flowers in the valley
\__/ Chante Moore
    Bosskey.net: Aliens vs. Predator 2 / http://www.bosskey.net/avp2/
 A personal guide to Aliens vs. Predator 2.



More information about the Python-list mailing list