Do you want to take your Python to the next level? Python is easy to learn. You can learn the basics in a day and be productive with it, but there are more-advanced constructs that you will eventually run across if you spend enough time with it. Don't be confused by these constructs; learn them, embrace them, and improve your code and the code of others.
This audiobook combines three popular guides into one. You will
Guide Functional Python & Comprehension ConstructsGuide Learning Iteration & Generators in PythonGuide Learning Python Decorators Write Python code like the masters. These constructs, while not necessary per se, allow you to be more succinct, to reuse code, and to think about code in a different way. You will
How the constructs work When to use them Real-life examples from the standard library Functional programming List comprehensions Generator expressions Set & dict comprehensions Iteration Generators Closures Decorators I have taught material similar to these constructs at conferences such as PyCon, OSCON, and Strata. This audiobook is based on my experience teaching and using Python for many years. I hope you learn something over the course of your listening. Maybe it will help you with your next task, code review, or job interview.
I first met Matt Harrison years ago when he gave a great tutorial on decorators and functions at the Southern California Linux Exposition. In less than an hour he managed to get a packed room understanding and writing their own decorators. I took copious notes, and wished there was a book he wrote that I could reference.
Fortunately, this is that book. ;-)
Matt starts with the functional built-ins of Python such as lambda, filter, map, reduce, adds in recursion, then tops it off with list, set, and dict comprehensions. It's great stuff and he explains it well.
The next part of the book delves into iteration and generators. If you know anything about Python's functional capabilities, you know this builds pretty much right off the first part. For me, I found this made the book feel like it built upon itself in a clever, conceptual sort of way.
Finally, the last part is a really nice piece on decorators, which means functions and more functions!
All in all I really liked this book and learned from it. If you have at least a basic understanding of Python and are interested in the language, you owe it to yourself to get this book.
Includes excellent examples with fairly comprehensive explanations for a wide variety of language features. Special care is taken to highlight the differences between Python 2 and Python 3, especially that some of the features which are available in Python2 are sometimes vastly different in behaviour (lazy methods rather than producing sequence upfront), implementation (map as built-in function VS. Built-in class), or location (moved from standard libraries). The only section that could benefit from further elucidation is that of Chapter 14 - Alternate Decorator Implementations.