Review: Python Tricks

Learning how to program in Python is easy, but what about learning how to program good, well-written, Pythonic code? Thanks to Python Tricks, it is easy.

Python Tricks, by Dan Bader, is not an usual book. Is not designed to teach you Python starting from your first “print(‘Hello World’)”.

Instead, Python Tricks is, as it says on the cover, a buffet of awesome Python features. It will unfold before your eyes some Python knowledge that even advanced and experts Pythonistas doesn’t know nor use.

So, this book is not for people starting their journey in Python or in the coding world. This book is for people who want more from the language and don’t want to just use it, but understand how it works, what it can do and the best way to do it.

Python Tricks is for people that use, love and want to master Python, learning the best solution to every problem.

This book is for Pythonistas, from a long time Real Pythonista

What you will find in the book

Divided by small, fast to read, chapters, in each one the writer introduces us one topic (Patterns for Cleaner Python or Common Data Structures in Python, for example), then starts giving the reader pill after pill of knowledge. Each “pill” is about 3-5 pages long and teaches you a feature of the topic in an easy, visible, easy to understand way. Also, it is pretty easy to pop up your python command line while reading the book and try what you are learning, playing with the code to interiorize the learnings.

I could write lines and lines, but why no reading an excerpt of the book?

Open the link and go straight to page 18. There you’ll learn how ‘is’ is not the same as ‘==’, and what are the best scenarios and use cases to use one instead of the other. Grab your Python command line or IDE and try the code. Play around it. Feel it.

At the end of each chapter you’ll find a few Key Takeaways of that chapter as a summary.

Each chapter also is independent of the others, so while the author (and I) recommends you to read it in order, you are free to go straight to a chapter that you are interested in (or working with!) then go back and forth.

I especially like this because after reading the book, I can revisit the chapter I’m working with, and apply it in a second.

Who should read Python Tricks?

If you come from another programming language and you want to write good, clean Pythonic code, if you want to become an advanced Pythonista, if you feel like you know all the basics but don’t know how to improve or if you want to learn the hidden and lesser-known features in Python, you should read Python Tricks.

Good, enjoyable, easy to read and short (sadly) that reads in a breeze but despite that, teaches you in minutes what other sources teach in pages and pages.

A must, if you use Python as your main or secondary language in both your job or as a hobbyist.

Buy Python Tricks (Ebook and paperback): https://www.amazon.com/Python-Tricks-Buffet-Awesome-Features-ebook/dp/B0785Q7GSY/

Click for more book reviews