[Tutor] Classes and "Self"

Mark A. Tobin Mark A. Tobin" <mtobin@bigfoot.com
Fri, 27 Apr 2001 09:24:32 -0400


Hi there,
I've been playing around with Python for a while now as my first real foray
into programming.  I've just started looking at creating classes as they
seem to be the more "mature" way to structure one's programming.  I can now
implement instances and what not, thanks to some of the great tutorials out
there, however I can't figure out what the "self" argument is all about.  It
is used throughout the program to refer to something, but I don't really
"get it".  As I said, I can use it (i.e.. repeat the structure I've seen in
the tutorials by rote), but I don't really know why or how I'm using it.
An explanation or a point to an explanation would be helpful,

Mark