We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fc7a908 commit e73ac56Copy full SHA for e73ac56
app/main.py
@@ -14,9 +14,8 @@ def __init__(
14
Animal.alive.append(self)
15
16
def __repr__(self) -> str:
17
- return f'{{{", ".join(
18
- f"{k.capitalize()}: {v}" for k, v in self.__dict__.items()
19
- )}}}'
+ sub_str = (f"{k.capitalize()}: {v}" for k, v in self.__dict__.items())
+ return f'{{{", ".join(sub_str)}}}'
20
21
22
class Herbivore(Animal):
0 commit comments