Search across all documentation pages
13 pages in this section.
What actually happens when Python runs a line of code - names, objects, namespaces, and scope - and why that single model explains variables, functions, and imports at once.
Learn Python fundamentals with 10 runnable examples. Explore basic concepts like variables, numbers, and the REPL, plus intermediate topics.
Learn how Python's dynamic typing allows names to refer to different object types. Understand reference semantics, mutability, and shared state.
Learn about Python's numeric types, including integers, floats, and exact decimals. Explore arithmetic operators and common floating-point issues.
Learn to format Python strings with f-strings, use string methods, understand Unicode, and differentiate bytes from str for robust text handling.
Learn Python control flow with if/elif/else, match/case for structural pattern matching, and for/while loops. Discover loop else clauses and short-circuiting.
Learn to build lists, dicts, and sets with comprehensions and use generator expressions for memory-efficient iteration and data processing.
Learn to define Python functions using positional and keyword arguments, *args, **kwargs, and understand LEGB scope rules.
Understand Python modules, packages, and the import system. Learn to split scripts, publish libraries, and manage dependencies with practical examples.
Learn to read and write files in Python using pathlib.Path, manage encodings, and ensure file closure with context managers.
Learn to create and manage isolated Python virtual environments using uv or venv to handle project dependencies and avoid conflicts.
Learn Python best practices for readable, correct, and maintainable code. Covers environment setup, tooling, code style, and fundamental habits for new projects.
A single-page roundup of every highlight bullet from the 12 pages in the Fundamentals section, grouped by source page so you can scan all 48 takeaways without opening each article individually.