This part is not correct
change it to
return "{} (health: {})".format(self.name, self.health) def __str__(self): passthe
__str__
method should return a stringchange it to
def __str__(self): return "{} (health: {})".format(self.name, self.health)Then create an instance of
Pichu
and print itpichu = Pichu() print(pichu)
Output:Pichu (health: 30)