# Python in Depth

Learn Python from your very first line of code to tools that save you hours: variables, decisions and loops, functions and data, files, errors and classes,…

Updated: November 19, 2026

## [Module 1: Python Basics](https://www.ask-codey.com/courses/python-in-depth/modules/1)

Write your first Python programs: install Python, VS Code and Git, find your way around the terminal, try code in the REPL, keep values in variables, ask for input, make decisions and repeat work with loops, then build a quiz game you can play in the terminal.

- [Getting Started with Python](https://www.ask-codey.com/courses/python-in-depth/chapters/python-getting-started) (5 topics, 9 lessons)
- [Values and Variables](https://www.ask-codey.com/courses/python-in-depth/chapters/python-values-and-variables) (6 topics, 6 lessons)
- [Decisions and Loops](https://www.ask-codey.com/courses/python-in-depth/chapters/python-decisions-and-loops) (4 topics, 7 lessons)

## [Module 2: Functions and Data](https://www.ask-codey.com/courses/python-in-depth/modules/2)

Package your code in functions, then organize real data: lists and tuples for things in order, dictionaries for looking things up by name, sets for things without duplicates, and comprehensions and sorting to reshape them all, then build a grade book that summarizes a class's scores.

- [Functions](https://www.ask-codey.com/courses/python-in-depth/chapters/python-functions) (3 topics, 5 lessons)
- [Lists and Tuples](https://www.ask-codey.com/courses/python-in-depth/chapters/python-lists-and-tuples) (3 topics, 5 lessons)
- [Dictionaries, Sets and Comprehensions](https://www.ask-codey.com/courses/python-in-depth/chapters/python-dictionaries-sets-and-comprehensions) (5 topics, 7 lessons)

## [Module 3: Building Real Programs](https://www.ask-codey.com/courses/python-in-depth/modules/3)

Build programs the way real ones are built: split code into modules, install packages in a virtual environment with pip, handle errors with exceptions and find bugs with the debugger, read and write text, CSV and JSON files, and describe your own things with classes and dataclasses, then build a contact manager that saves to JSON.

- [Modules and Packages](https://www.ask-codey.com/courses/python-in-depth/chapters/python-modules-and-packages) (3 topics, 4 lessons)
- [Errors and Debugging](https://www.ask-codey.com/courses/python-in-depth/chapters/python-errors-and-debugging) (3 topics, 4 lessons)
- [Files: Text, CSV and JSON](https://www.ask-codey.com/courses/python-in-depth/chapters/python-files) (3 topics, 4 lessons)
- [Classes and Dataclasses](https://www.ask-codey.com/courses/python-in-depth/chapters/python-classes-and-dataclasses) (4 topics, 5 lessons)

## [Module 4: Testing and Quality](https://www.ask-codey.com/courses/python-in-depth/modules/4)

Prove your code works and keep it tidy: write tests with pytest (edge cases, errors, fixtures and temporary files), add type hints and check them with mypy, and format and lint with Ruff, then build a library-fines calculator, test first.

- [Testing with pytest](https://www.ask-codey.com/courses/python-in-depth/chapters/python-testing-with-pytest) (2 topics, 4 lessons)
- [Type Hints, Linting and Formatting](https://www.ask-codey.com/courses/python-in-depth/chapters/python-type-hints-and-tidy-code) (4 topics, 5 lessons)

## [Module 5: Automation](https://www.ask-codey.com/courses/python-in-depth/modules/5)

Put Python to work: sort and rename files and folders with pathlib and shutil, turn a script into a tool with command-line options, run it on a schedule, and fetch live data from a web API with requests, with a saved copy for when the network is down, then build a weekly report that writes itself.

- [Automating Files and Folders](https://www.ask-codey.com/courses/python-in-depth/chapters/python-automating-files-and-folders) (3 topics, 5 lessons)
- [Calling Web APIs](https://www.ask-codey.com/courses/python-in-depth/chapters/python-calling-web-apis) (4 topics, 6 lessons)

## [Module 6: Where Python Goes Next](https://www.ask-codey.com/courses/python-in-depth/modules/6)

Try the three directions Python goes from here, an hour each: a first pandas table and chart, a first model that guesses and a way to tell when it's wrong, and a first web API route with its test. Each taste ends by naming the course that goes further, and the course closes with your final capstone.

- [A Taste of Data Analysis](https://www.ask-codey.com/courses/python-in-depth/chapters/python-taste-of-data-analysis) (2 topics, 3 lessons)
- [A Taste of Machine Learning](https://www.ask-codey.com/courses/python-in-depth/chapters/python-taste-of-machine-learning) (2 topics, 3 lessons)
- [A Taste of Web APIs](https://www.ask-codey.com/courses/python-in-depth/chapters/python-taste-of-web-apis) (3 topics, 4 lessons)

Source: https://www.ask-codey.com/courses/python-in-depth
