Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialTalent Majuru
1,732 PointsHow do I return a message with the name attribute?
Where am I going wrong, I'm stuck.
class Student:
name = "John"
def praise (self):
print ("You're doing great," + self)
Student.praise(name)
2 Answers
Steven Parker
231,275 PointsYou're close, but:
- instead of just "self", to access the name you'll need "self.name"
- the challenge wants you to return the result string
- you won't need to "print" anything
- you only need to define the method, you don't need to call it
Talent Majuru
1,732 PointsThanks a lot!