The only way to master a skill is practice, practice, practice. That’s exactly what you’ll do in Python Workout, Second Edition! In this instantly-valuable book you’ll work through 50 carefully selected exercises that flex your programming muscles. This revised new edition covers the latest version of Python and adds updated content and diagrams.
In Python Workout, Second Edition you’ll find 50 exercises,
• Working with text using strings • Mastering dictionaries and sets • Reading, writing, and manipulating files • Functional programming with comprehensions • Python modules and packages • Creating iterable objects
To become a champion Python programmer you need to build mental muscle by putting your hands on the keyboard. Each carefully selected exercise in this unique book adds to your Python prowess—one important skill at a time. You’ll practice core Python language features and techniques that reinforce the programming patterns you’ll use every day and build the skills you need to troubleshoot your programs.
About the book
Python Workout, Second Edition hones your Python chops just like you would in the gym. Repetition of key skills builds muscle memory. New challenges increase your strength. Combining new and old techniques encourages flexibility. Expert Python coach Reuven Lerner guides you through each exercise with a detailed solution designed to give you a deeper fluency and understanding of Python.
About the reader
For readers with basic Python knowledge.
About the author
Reuven M. Lerner teaches Python and data science to companies around the world. He is the author of Python Workout and Pandas Workout.
A great book to learn get better at python with exercises Python has become a very popular language, with the rise of GenAI and in the past as the main language for data science, but I am curious how well people really understand the language. For me, I have been programming in Python for off and on about 12 years so I thought I knew it well, but there are times I will run into a situation where I wonder if there is more I should learn. Well, this book helped to answer that, and the main area for me was in functional programming, as I love using FP but didn't really think of Python that way, just as a dynamic language. There were two chapters just on this section, but then just learning more about how it handles strings was interesting, and if you are new to Python he starts off with interesting exercise and tells little stories about them before you tackle them. By the time you are finished you will find that your python coding will probably change as you are better able to solve problems than before you were using it. Now, I realize with vibe-coding many people will think they don't need to actually learn a language, but for the sake of those that will follow and need to maintain or improve on your code, please consider taking some time to learn the language you are going to be doing development in, as these tools may be useful but they won't necessarily make the best choices as they are trained on what people put on Stackoverflow and GitHub as quick and dirty examples of how to do something. Manning Publications Co. Divya Aravind https://www.amazon.com/Python-Workout...
As a bioinformatician and software developer I have been working with the Perl programming language (among others) since 2008. However, for the past ~ ten years the Python language has been growing and growing in popularity, especially in the field of Data Science; so I have been under more and more pressure to contribute code that the others on my team can also read (Python has become a sort of lingua franca scripting language among many biologists). Over time I have absorbed and taught myself the basic fundamentals, but most of the time I am debugging or copying someone else's code, and I needed to hone my Python skills for bigger projects. This book was perfect for me in this regard. Much of the material was familiar, or familiar enough, but I was amazed to discover that in each chapter I learned at least a couple of pythonic idioms or functions/operators that I had never heard of at all. In my opinion this is an excellent choice for someone who is past the phase of being a beginner in Python, and wants to move on to more advanced topics (with lots of solved examples to practice on). The author has had experience with many programming paradigms over his career, and brings that valuable perspective to his work.
This book offers a refreshingly thoughtful way to teaching fundamental of programming in Python. What stood out most to me was the author's ability to distill core concepts into simple yet powerful exercises that genuinely reinforce learning rather than encourage passive reading. The structure nudges readers to actively think and apply concepts, and the inclusion of optional stretch goals adds meaningful depth for those who want to push further. The writing style feels approachable, with a narrative flow that keeps the material engaging without sacrificing rigor. Even as an experienced practitioner, I found value in the clarity of explanation and the pedagogical choices, particularly for anyone who may find themselves teaching or mentoring others. This is a well crafted book that does justice to its title and serves as a strong foundation for beginners and early to intermediate Python learners alike.
Python Workout covers an expansive range of topics and real-world scenarios designed to bridge the gap between "knowing" Python and "writing" it fluently. For those looking to evolve their existing experience, the book’s hands-on approach offers an irresistible avenue for skill-building.
In this second edition, Reuven Lerner significantly expands the exercise library while integrating updated syntax and modern workflows, including working alongside AI. It is an essential addition for anyone looking to sharpen their Pythonic intuition through challenging examples that test—and occasionally confound—even experienced developers.
This book is simple and practical. The short exercises make it easy to practise Python regularly without feeling overwhelmed. It really helps build confidence with core concepts if you’re still learning or getting back into Python.
but if you already have decent experience, many exercises may feel repetitive or too basic. It’s a good practice book, but not something that will deeply challenge advanced readers.
Reuven Lerner pours years of experience as a Python trainer into this book. Call it a page turner an you won't be wrong. He knows the precise points where learners suffer, so these exercises communicate the key ideas amongst the stranger things of Python into something beginners just like you can master through thoughtful problems.
This is an excellent book to practice your Python skills. The formula of the book makes learning easy and fun through hands on training. I would recommend this book to anyone who wants to improve their core Python.