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 trialDwarika Mishra
1,827 PointsAnimal.noise() returns self.sound.lower(). Make Sheep.noise() return the uppercased version of the instance's sound.
What wrong i am doing here that it is showing my code wrong and every time its saying it looks like Task is no longer passing
from animal import Animal
class Sheep(Animal):
sound ='bark'
def noise(self):
return self.sound.upper()
2 Answers
Sean T. Unwin
28,690 PointsThe indentation is too far. Make sure your indents are 2 or 4 spaces and consistant. Ideally a multiple of 4 in the real world. The Challenge editor accepts 2 spaces, where 2 spaces equals 1 tab.
Hanley Chan
27,771 PointsHi, Looks like it's all correct except some indenting errors
from animal import Animal
class Sheep(Animal):
sound ='bark'
def noise(self):
return self.sound.upper()