« All Events
4:30 PM – Python OOP – Gamas
April 5, 2022 @ 4:30 pm - 5:30 pm
Today We Do
- We completed SchoolApplication
- We started learning about Inheritance
- We started MonsterInheritance project
Homework
- Continue on MonsterInheritance project
- We want to continuously list all monsters and then get user selection like below. If user enter “exit” stop the loop. To list all the monsters like below, you have to use for loop to go through all elements inside the dictionary. Look at Feb15_StudentClass.py if you forgot how to loop through a dictionary.
-
Your have 200 health remaining.
Please choose your monster:
Troll - 50 healths - 30 Max attack points.
Water Golem - 30 healths - 20 Max attack points.
Dragon - 100 healths - 50 Max attack points.
Enter your selection (enter "exit" to quit): asdasdf
Please choose your monster:
Troll - 50 healths - 30 Max attack points.
Water Golem - 30 healths - 20 Max attack points.
Dragon - 100 healths - 50 Max attack points.
Enter your selection (enter "exit" to quit): exit