Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
shoyer
on March 1, 2014
|
parent
|
context
|
favorite
| on:
Python Best Practice Patterns
You create a list, so this expression won't shortcut like or. Or is definitely the right way to write an expression like this. Any has its place, but mostly when it's input is a generator, e.g.,
any(k in obj for k in other)
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: