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 trial

Python Object-Oriented Python Inheritance Multiple Superclasses

kushagra jain
PLUS
kushagra jain
Courses Plus Student 2,563 Points

Can't understand anything.

what to do ?

You need to be more specific. What are you having trouble with? What have you tried? Where have you looked? Just asking what to do and saying you don't understand anything doesn't really help people that would help you.

2 Answers

Try seeing the videos again and understanding the basics. Do you know how to create a class, method, attributes, and init(). Then do you understand how to inherit simply. Then do you understand how to use super to reduce code and have base class deal with things.

Try creating an animal class, then a Canidae class (https://en.wikipedia.org/wiki/Canidae), then dog, wolf and fox classes that inherits from this. Then a subclass for different types of wolves. You can also create a class for sneakiness and cunning that foxes and wolves can inherit from, but not dogs. See what else you can add using the mental model of a biological family tree.

This is lame to say, looking over the teacher’s notes and the questions posted due help to understand the where others are struggling.