The need to put "self" in every method

Steven Bethard steven.bethard at gmail.com
Tue May 31 12:24:12 EDT 2005


Fernando M. wrote:
> i was just wondering about the need to put "self" as the first
> parameter in every method a class has because, if it's always needed,
> why the obligation to write it? couldn't it be implicit?

py> import this
The Zen of Python, by Tim Peters

Beautiful is better than ugly.
Explicit is better than implicit.
...


STeVe



More information about the Python-list mailing list