- This event has passed.
6 PM – Python OOP – Joel
January 8 @ 6:00 am - 7:00 pm
Today we did:
- We did a new project called ZooSystem to practice with inheritance and overriding.
Homework:
- In the ZooSystem, make a new function called initialize_animals, and inside, make one of each: a Reptile, Bird, and Mammal. Add them all to the dictionary, and then make sure to call this function right before the while True loop in the application_loop.
- Make sure to complete the other two selections, which is “Show daily activities” and “Calculate total cost”.
- Show daily activities is the showing the get info, what the animal eats, what sound it makes, and its daily care cost for each animal in the dictionary.
- Calculate total cost is getting the total cost of how much it costs to take care of all the animals combined. Hint: you should go through each animal, have a cost variable = 0, and then add one by one each animal’s cost to the cost variable to get the total.
- If you have any questions, feel free to email me at joel@ayclogic.com.