diff --git a/app/main.py b/app/main.py index af369a78..34696283 100644 --- a/app/main.py +++ b/app/main.py @@ -30,5 +30,5 @@ class Carnivore(Animal): def bite(herbivore: Herbivore) -> None: if isinstance(herbivore, Herbivore) and not herbivore.hidden: herbivore.health -= 50 - if herbivore.health <= 0: + if herbivore.health <= 0 and herbivore in Animal.alive: Animal.alive.remove(herbivore)