Python Course

Python is one of the world's most popular programming languages — readable, versatile, and used for everything from automation scripts to web back ends, data analysis and AI. This course takes you from your first line of code to writing clean, tested, real-world programs, with runnable examples on every page.

What you'll learn

The course has 56 lessons in eight parts:

  • Getting Started — installing Python, syntax and indentation, variables, data types, numbers, strings, formatting, booleans, operators, input and output.
  • Control Flow — if/elif/else, match, while and for loops, break, continue and loop else.
  • Data Structures — lists, comprehensions, tuples, sets, dictionaries, slicing, unpacking and the collections module.
  • Functions — arguments, scope, lambdas, recursion, type hints, decorators, iterators and generators.
  • Object-Oriented Python — classes, inheritance, special methods, properties, dataclasses and enums.
  • Errors & Files — handling and raising exceptions, reading and writing files, paths, JSON and CSV.
  • Modules & the Standard Library — imports and packages, pip and virtual environments, maths, dates, regular expressions, itertools and asyncio.
  • Writing Good Python — testing, Pythonic style, recent Python versions and a final project.

Every example shows its real output, and every runnable example has been checked by executing it with Python 3.14. The Try it yourself editors run genuine Python in your browser — press Run or Ctrl+Enter. The first run downloads the interpreter, which takes a few seconds.

No previous programming experience is needed.

Practice

  • Playground — a blank editor for your own experiments.
  • Exercises — fill-in-the-blank tasks and coding problems with solutions.
  • Quiz — test your understanding across the whole course.
  • Syllabus & Study Plan — learning outcomes and a week-by-week schedule.

Lessons

Getting Started

  1. Introduction to Python
  2. Installing & Running Python
  3. Syntax, Indentation & Comments
  4. Variables
  5. Data Types
  6. Numbers
  7. Type Conversion
  8. Strings
  9. String Methods
  10. String Formatting with f-strings
  11. Booleans, Truthiness & None
  12. Operators
  13. Input & Output

Control Flow

  1. if, elif & else
  2. Match Statements
  3. while Loops
  4. for Loops & range()
  5. break, continue & Loop else

Data Structures

  1. Lists
  2. List Methods
  3. List Comprehensions
  4. Tuples
  5. Sets
  6. Dictionaries
  7. Dictionary Methods & Comprehensions
  8. Slicing & Unpacking
  9. The collections Module

Functions

  1. Functions
  2. Arguments in Depth
  3. Scope
  4. Lambdas & Higher-Order Functions
  5. Recursion
  6. Type Hints
  7. Decorators
  8. Iterators & Generators

Object-Oriented Python

  1. Classes & Objects
  2. Inheritance
  3. Special Methods
  4. Properties, Class & Static Methods
  5. Dataclasses & Enums

Errors & Files

  1. Handling Exceptions
  2. Raising & Custom Exceptions
  3. Reading & Writing Files
  4. Paths & the File System
  5. JSON & CSV

Modules & the Standard Library

  1. Modules & Packages
  2. pip & Virtual Environments
  3. math, random & statistics
  4. Dates & Times
  5. Regular Expressions
  6. itertools & functools
  7. Async Programming with asyncio

Writing Good Python

  1. Testing Your Code
  2. Pythonic Code & PEP 8
  3. What's New in Python
  4. Project: A Sales Data Report

Practice

  1. Python Playground
  2. Python Exercises
  3. Python Quiz
  4. Syllabus & Study Plan
Where to start: begin with Introduction and work through in order. Afterwards, continue with NumPy, pandas or Django, depending on what you want to build.