Python guides
Every published Python guide, newest first, with practical examples you can copy into your own project.
3,965 guides across 14 topics
Topics
Popular Python guides
Most readLatest Python guides
Page 134 of 179Python Function Declaration: Syntax and Parameters
Learn the syntax for declaring functions in Python, including parameters, return values, default arguments, *args/**kwargs, and type hints.
Python Nested Unpacking: Syntax and Patterns
Learn how to unpack nested tuples and lists in Python, use star expressions for variable-length data, and avoid common dictionary and string pitfalls.
How to Swap Variables in Python Using Tuple Unpacking
Learn how to swap variables in Python using tuple unpacking, why the evaluation order matters, and how to avoid common mistakes.
Python **kwargs Unpacking: Syntax, Usage, and Pitfalls
Learn how Python's **kwargs unpacking works in function definitions and calls, with practical examples and common mistakes to avoid.
Python *args Unpacking: Syntax and Common Pitfalls
python *args unpacking: Learn how *args packs extra positional arguments and how * unpacks iterables into function calls, with practical examples and pitfalls.
Python Starred Expression: Unpacking and Expansion
python starred expression: Learn how Python starred expressions work in assignments, function calls, and definitions, with practical examples and common pitfalls.
Python Extended Unpacking: Syntax and Practical Uses
Understand Python's extended unpacking syntax for assignments, function calls, and iterable handling, with practical examples and common pitfalls.
Python Iterable Unpacking: Syntax and Pitfalls
Learn how Python iterable unpacking works: basic assignment, starred expressions, loops, function calls, dictionaries, and common pitfalls.
Python Sequence Unpacking: Syntax and Common Pitfalls
Learn Python sequence unpacking: tuple and list unpacking, extended unpacking with *, nested patterns, and how to avoid ValueError.
Python Unpacking: Syntax, Edge Cases, and Patterns
python unpacking: Understand Python unpacking: sequence assignment, starred expressions, dictionary unpacking, and function argument handling with practical examples.