Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Solution #851

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Solution #851

wants to merge 3 commits into from

Conversation

rinotokun
Copy link

No description provided.

app/main.py Outdated
Comment on lines 11 to 18
list_of_people = []
for character in people:
list_of_people.append(
Person(
name=character["name"],
age=character["age"]
)
)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider using a list comprehension for concise and readable code.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I fixed it

app/main.py Outdated
)
)
for index in range(len(list_of_people)):
if "wife" in people[index]:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider using dictionary's get method for cleaner code.

Copy link

@Polyakiv-Andrey Polyakiv-Andrey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants