Python Quest · part of Formula Quest
Learn Python by writing real code.
From your first line to data analysis, automation and tested software. Every lesson runs real Python 3.14.2 in your browser, and every exercise tells you exactly which requirement your code meets and what to check next.
An exercise from Track 5
def average(scores):
if not scores:
return 0
return sum(scores) / len(scores)
print(average([82, 91, 77]))Returns the mean of the scores
Rounds the result to one decimal place
average([82, 91, 77]) returned 83.33333333333333; expected 83.3. Use round(value, 1) before returning.
How it works
Real Python, nothing to install
Code runs in a real CPython interpreter inside your browser, isolated from the page. input(), files, CSV, JSON, NumPy, pandas and matplotlib all work. The guide explains what differs from Python on your own computer.
Feedback that teaches
Checks run your code against normal and edge cases and tell you which requirement failed, what was expected, what your code produced, and what to look at next. Three hints, then the solution.
Practice that adds up
Every lesson ends in graded exercises, every track in a test, and the course in a capstone. Your dashboard shows what you've mastered and what to review.
The curriculum
Open the learning map →- Track 1 · beginner · FreeGetting Started with PythonWrite, run and debug your first Python programs, assuming no programming experience at all.11 lessons · 40 exercises
- Track 2 · beginner · FreeVariables, Data Types and OperatorsStore values in variables, work with numbers, text and booleans, convert between types and process input.11 lessons · 45 exercises
- Track 3 · beginnerConditional LogicMake programs choose what to do with if, elif and else, and express real business rules as conditions.11 lessons · 44 exercises
- Track 4 · beginnerLoops and IterationRepeat work with for and while loops, count and accumulate results, and avoid loops that never end.11 lessons · 44 exercises
- Track 5 · beginnerFunctions and Program StructurePackage logic into reusable functions with parameters and return values, and structure programs clearly.12 lessons · 48 exercises
- Track 6 · intermediateCore Data StructuresOrganise data with lists, tuples, dictionaries and sets, and transform collections with comprehensions.12 lessons · 51 exercises
- Track 7 · intermediateWorking with TextClean, validate, parse and format real-world text, including regular expressions and Unicode basics.11 lessons · 46 exercises
- Track 8 · intermediateFiles, CSV and JSONRead and write files, process CSV and JSON data, validate records and build small data pipelines.11 lessons · 46 exercises
- Track 9 · intermediateExceptions and DebuggingRead tracebacks, handle exceptions deliberately, validate input and debug code systematically.11 lessons · 45 exercises
- Track 10 · intermediateModules, Libraries and the Python EcosystemUse the standard library, organise code into modules, and understand pip, virtual environments and dependencies.12 lessons · 49 exercises
- Track 11 · intermediateObject-Oriented ProgrammingModel real problems with classes, objects, methods, inheritance, composition, properties and dataclasses.12 lessons · 52 exercises
- Track 12 · advancedIntermediate and Advanced PythonUse iterators, generators, decorators, closures, context managers, type hints and asyncio — and know when not to.12 lessons · 51 exercises
- Track 13 · advancedTesting and Software QualityWrite tests that catch real bugs, refactor safely, and structure code so it stays reliable and maintainable.12 lessons · 39 exercises
- Track 14 · advancedData Analysis with PythonLoad, clean, analyse and visualise data with NumPy, pandas and matplotlib, and communicate what it shows.12 lessons · 45 exercises
- Track 15 · advancedAutomation and Practical PythonAutomate repetitive work: batch-process files, combine exports, validate data, generate reports and log failures.11 lessons · 44 exercises
- Track 16 · advancedAlgorithms and Problem SolvingDesign clear algorithms, choose efficient data structures, and reason about the cost of different approaches.12 lessons · 49 exercises
- Track 17 · advancedApplied Projects and CapstonesCombine everything in substantial projects built from realistic requirements, with automated checks at each milestone.12 lessons · 73 exercises
Free to start
Tracks 1 and 2, the first lesson of every track, the Python playground, the 20-dataset library and the runtime guide are free with a Formula Quest account. The full course is included in Formula Quest memberships that cover Python Quest.