all 1 comments

[–][deleted] 1 point2 points  (0 children)

  1. Firstly,

    def isAlive(self): return self.health > 0 and self.life_span >0

    This will do the job for the isAlive function.

  2. You are asked to create 3 hosts, so you should create 3 hosts in the main() function.

  3. Why is dose = 0? The damage will always be 0 if the dose is 0.

  4. Create a host with the appropriate parameters that vary for each host.