On Sun, Mar 10, 2013 at 4:57 AM, Vincent Balmori
<[email protected]> wrote:
> I am trying to use a __str__ method to display the values of attribute mood
> = self.hunger + self. boredom.

__str__ has to return a string:

http://docs.python.org/3/reference/datamodel.html#object.__str__

Bookmark the "_" index of the docs as a quick reference for special methods:

http://docs.python.org/3/genindex-_.html

For the basic descriptions, follow the "(object method)" links.
_______________________________________________
Tutor maillist  -  [email protected]
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to