American Young Coder (AYC)

AYC logo
Loading Events

« All Events

  • This event has passed.

5 PM – Python Object Oriented Programming – Shawn

July 14, 2023 @ 5:00 pm - 6:00 pm

Today We Did
  1. Finished and reviewed Supermarket Application
  2. Learned what inheritance is.
  3. Started the MonsterInheritance project. Created our Monster class, Dragon, and Troll.
  1. Copy pages 168 to 170 in your textbook into a file named
  2. Create a file in  your project called
    1. Create a class called WaterGolem that inherits from Monster
    2. Use super() to call the constructor, creating a Monster that has Water Golem as its species, and pass in health and max attack as parameters.
    3. Override the receive_magic_attack function.
      1. The Water Golem is immune to fire attack
      2. If the magic type is water, the damage is halved
      3. Otherwise, the attack is done normally, as done in Monster

Feel free to let me know if you have any questions — reach me at


July 14, 2023
5:00 pm - 6:00 pm
Verified by MonsterInsights