2 ms·
I think your book goes for breadth of topics while his primarily focuses on solid understanding of iterators, generators, and decorators. p.s. I only looked at
by p1esk 11y ago
I think your book goes for breadth of topics while his primarily focuses on solid understanding of iterators, generators, and decorators.
p.s. I only looked at the "Enumeration" page in your book, and I don't think it belongs in an "intermediate" level Python book. The use of optional arguments makes little sense to me (not something I wanted to know about Python after I learned the basics).
I'm sure other chapters have more relevant content though, and I appreciate your effort.
- heyalexej 11y agoI consider myself somewhere in the spectrum between beginner and intermediate and I use enumeration quite often. I picked it up early on in a tutorial by Andrew Montalenti (founder of http://www.parsely.com http://www.parsely.com and quite active in the Python community) and use it ever since instead of wrapping it into another loop like beginner tutorials teach you. For example if I need to read in a file with 5 million lines but for debugging or performance optimization reasons want to break the loop after 1K lines.
- p1esk 11y agoAll beginner tutorials I used introduced "enumerate" early on. Indexing is probably the first thing you're wondering about when you start coding in Python after coding in C.