About the Book
The order of topics is designed to stimulate and strengthen skills such as logic, problem solving, and clean code writing.
Python syntax is explained extensively in a simple but precise way, focusing on concepts and vocabulary.
Topics include data types (strings, lists, dictionaries, etc.), if/else constructs, for loops, while loops, functions, modules, and object‐oriented programming.
Examples are embedded in narrative to provide context and encourage memorization, and they are enriched with suggestions for code pronunciation.
The book includes thirty‐eight chapters, each corresponding to a Jupyter Notebook where you can play with the code explained in the text.
Chapters contain both theoretical exercises, to verify the understanding of concepts, and coding exercises, to learn by doing.
Exercise solutions are described in the community forum, where you can ask questions and propose alternative solutions.
At the end of each chapter, you will find recaps and “in more depth” sections, with suggestions, tips, and curiosities.
The book is written in a simple and colloquial language while being precise and detailed.
The material of this book was tested and refined over more than a thousand hours of one‐on‐one teaching,
with international students of various educational backgrounds.
DOWNLOAD THE JUPYTER NOTEBOOKS
Get the Notebooks for the published chapters. You can download them one by one from below, or all of them at once here
PART 1: Creating the basics
PART 2: Introduction to lists and if/else statements
- In a bookstore
Lists and if... in... / else...
- Grocery shopping
List methods: .append() and .remove()
- Customizing the burger menu
List methods: .index(), .pop(), and .insert()
- Traveling around the world
- Senses, planets, and a house
Changing, adding, and removing list elements using slicing
PART 3: Introduction to the for loop
PART 4: Numbers and algorithms
PART 6: Focus on lists and for loop
- Overview of lists
Operations, methods, and tricks
- More about the for loop
Various ways of repeating commands on lists and beyond
- Lists of lists
Slicing, nested for loops, and flattening
PART 7: Dictionaries and overview of strings
- Inventory at the bookstore
- Trip to Switzerland
Dictionaries with lists as values
- Counting, compressing, and sorting
Dictionary use cases
- Overview of strings
Operations, methods, and tricks
PART 8: Functions
- Stationary for a party
- Username and password
- People's age and odd numbers
Type and value errors, and return
- Jupyter notebooks and modules
Working with Jupyter Notebook and an IDE
PART 9: Misc
- Online shopping
Reading and writing text files
- Final Python tricks
What's more in Python
PART 10: Object oriented programming
- I need a bank account!
Classes and objects
- Improving a bank account
- What if I need a checking account?
- I also need a savings account
Join the LPWJ community
The Learn Python with Jupyter (LPWJ) community is a free space where you can find exercise solutions and ask questions
Join us in 3 easy steps!
DERIVED WORK, MENTIONS, AND BOOK PRESENTATIONS
Work using Learn Python with Jupyter, mentions, and book presentations
- Juno | JupyterLab-Based STEM Learning Environment: An immersive STEM learning environment for middle school students using JupyterLab, leveraging Docker Compose to orchestrate container deployments - By Rodrigo Ernesto Álvarez Aguilera