[Tutor] exercise with classes

Alan Gauld alan.gauld at btinternet.com
Mon Feb 6 19:15:26 CET 2012


On 06/02/12 16:12, Tonu Mikk wrote:
> Alan, thanks for explaining about passing objects to classes.  This is
> an important concept for me to understand.
>
> I tried running the code, but run into an error that I could not resolve:
>
> TypeError: doIt() takes no arguments (1 given).

Sorry the code was only meant for illustration and had not nbeen tested.
I forgot the self in the definition of doit()... And probably other 
stuff too!

Alan G.



More information about the Tutor mailing list