Do I always have to write "self." ?
Louis M. Pecora
pecora at anvil.nrl.navy.mil
Sun Apr 30 09:53:34 EDT 2000
In article <slrn8giv6f.fl9.scarblac-spamtrap at flits104-37.flits.rug.nl>,
Remco Gerlich <scarblac-spamtrap at pino.selwerd.nl> wrote:
>
> No, you can just declare methods like
>
> class Foo:
> def Method(s,x):
> s.y = x
>
> The name 'self' is just a convention.
Ahhhh...gotcha. I keep forgetting how type-lose Python is. And how
flexible. Thank you.
More information about the Python-list
mailing list