Skip to main content
CodeMentor AI
All tracks
🐍L1 · 9 modules · 174 lessons

Python Foundations

From zero to confident with Python basics

Interactive lessons across 9 modules — print/variables, types, conditions, loops, lists, dicts, functions, strings, errors, and real-world mini-projects. First 15 lessons free, no signup.

Browse all 174 lessons →Try the first lesson — no signup
174
lessons
9
modules
16
capstone missions
18
languages
What you'll learn

From day one

  • Variables, types, operators, conditions, loops — the literal building blocks
  • Lists, dicts, sets, tuples — when to use each and the perf tradeoffs
  • Functions, closures, decorators, generators
  • Strings, formatting, regex basics
  • Files, errors, debugging — handle real-world data
  • Comprehensions, lambda, map/filter — Pythonic idioms
  • Mini-projects every 10 lessons: calculator, todo CLI, file organizer, etc.
  • Every lesson runs in your browser — no install, no setup, works on mobile
Curriculum

9 modules · 174 interactive lessons

#1Module 1 · Fundamentals of syntax
#2Module 2 · Data structures
#3Module 3 · Functions and strings
#4Module 4 · Object-oriented programming
#5Module 5 · Files, errors, stdlib
#6Module 6 · Concurrency and parallelism
#7Module 7 · Advanced stdlib
#8Module 8 · Modern Python and capstone
#9Module 9 · Bonus: mini-projects
See all 174 lessons →
From zero to building

Day 1 vs Day 60

The same hands. Two months apart. This is what 174 interactive Foundations lessons buy you.

📅 DAY 1 · LESSON 1Hello World
# First line of Python you ever write
print("Hello, World!")
🚀 DAY 60 · CAPSTONEWeather CLI · 38 lines
from dataclasses import dataclass
from typing import Iterable
import json, sys, urllib.request

@dataclass
class Forecast:
    city: str
    temp_c: float
    condition: str

    @classmethod
    def from_api(cls, payload: dict) -> "Forecast":
        return cls(
            city=payload["name"],
            temp_c=payload["main"]["temp"] - 273.15,
            condition=payload["weather"][0]["description"],
        )

def fetch(city: str, key: str) -> Forecast:
    url = (
        "https://api.openweathermap.org/data/2.5/weather"
        f"?q={city}&appid={key}"
    )
    with urllib.request.urlopen(url, timeout=5) as r:
        return Forecast.from_api(json.load(r))

def report(cities: Iterable[str], key: str) -> None:
    for c in cities:
        f = fetch(c, key)
        print(f"{f.city:15} {f.temp_c:5.1f}°C  {f.condition}")

if __name__ == "__main__":
    report(sys.argv[1:], key="<your-key>")

Dataclasses, type hints, HTTP, JSON parsing, CLI args — all introduced one concept at a time across modules 1 through 10. Nothing skipped, nothing magic.

Portfolio

Three real projects, not toy exercises

Capstone missions ship working programs you can show. Each one introduces a concept set deeply enough to put on a resume bullet.

~/inventory
$ python inv.py add "USB-C cable" --qty 12
✓ added (id 3, qty 12)

$ python inv.py list --low-stock
id  item              qty
─── ───────────────── ───
1   Notebook          2  ⚠
2   Pen 0.5mm         4  ⚠

$ python inv.py export --to csv
✓ wrote inventory.csv (38 rows)

CLI Inventory Manager

argparse, dataclasses, CSV I/O, error handling. ~modules 6–10.

currency.py● running
>>> convert(100, "USD", "UAH")
4012.0   # via openexchangerates.org

>>> convert(50, "EUR", "GBP")
42.18

>>> rates(["EUR","GBP","JPY"])
{
  "EUR": 0.92,
  "GBP": 0.78,
  "JPY": 156.4
}

Currency Converter API

HTTP requests, JSON parsing, caching, type hints. ~modules 8–11.

md2html.py92 lines · 100% test coverage
# Recipes

**Quick** pasta in
*10 minutes*.

- olive oil
- garlic
- pepper

Recipes

Quick pasta in 10 minutes.

  • olive oil
  • garlic
  • pepper

Markdown → HTML Converter

Regex, classes, recursion, unit tests with pytest. ~modules 10–13.

Frequently asked

Do I need to install Python to do this track?

No. Python runs in your browser via Skulpt — open lesson 1 and you're already coding. Works on a phone too.

How long does the Foundations track take?

Average ~10 minutes per lesson across 9 modules. At 5 lessons a day that's about 5-6 weeks; most learners finish in 4-8 weeks depending on pace.

What if I've programmed in another language before?

Skim the first 30 lessons (syntax + basic types) and jump in at module 3. The platform tracks your progress regardless of where you start.

Is the Foundations track enough to get a junior dev job?

Foundations alone teaches the Python part. Pair it with FastAPI or Data Science track + 1 portfolio project + interview prep to be job-ready.

How much of Foundations is free?

First 15 lessons no signup, no card. After that a 7-day full-library trial — see /pricing.

First 15 lessons free, no signup

All 174 lessons unlock for $12/month or $89/year. 7-day free trial — card required, cancel in 1 click anytime in Settings.

See pricing