Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Which is more Pythonic?

list() or []

dict() or {}

set() or ????

I would argue that the left is more pythonic and expressive.



Don't forget tuple() and ().

I don't think any are more pythonic. They are all valid python.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: