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

A bug at the project description page #4

Closed
buriy opened this issue Aug 13, 2018 · 1 comment
Closed

A bug at the project description page #4

buriy opened this issue Aug 13, 2018 · 1 comment

Comments

@buriy
Copy link

buriy commented Aug 13, 2018

new_kids_in_town = [Person('Chris', 18), Person('Danny', 16), Person('John', 17)]
people += new_kids_in_town # Also works: people = people.concat(new_kids_in_town)

teenagers = people.where(lambda p: 20 >= p.age >= 13)
danny = teenagers.first(lambda t: t.name == 'Danny')            # <Person name="Danny" age="16">
oldest_teen = teenagers.last()                                  # <Person name="Chris" age="18">

.last() method doesn't return max age but the last in the list, right? Should return "John,17 yo" then.

@avilum
Copy link
Owner

avilum commented Aug 19, 2018

You are right, Thanks a lot.

@avilum avilum closed this as completed Aug 19, 2018
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

No branches or pull requests

2 participants