[Tutor] Help with understanding classes

Robert Sjöblom robert.sjoblom at gmail.com
Sat May 21 12:24:34 CEST 2011


I'm trying to wrap my head around classes and their attributes, but am having a hard time doing so. The websites and books that I have consulted haven't been much help; most of them assume prior programming/oop experience, something I lack. 

From what I understand it's a "blueprint", so each time you instantiate it you run whatever's in the __self__ part is assigned to the instance. What I'm wondering is how to access and change attributes in the instance (whatever it might be; a list, a specific value, a string...).

I just can't seem to grasp the concept or syntax very well, and none of the sources I've found go to great lengths explaining them to someone as thick-headed as me. So if anyone could take the time to explain, or point me to sources to read, I'd be grateful

Thanks in advance, and best regards,
Robert S. 
Sent from my iPhone


More information about the Tutor mailing list