The Python Journey

Follow the guides below to go from setting up a modern Python >=3.13 environment with uv to mastering the algorithms, libraries, and reusable patterns behind my Advent of Code solutions.

Chapters Index

  1. Getting Started with Python
  2. Logging
  3. Timing and Progress
  4. Opening and Reading Files
  5. Functions
  6. My AoC Template
  7. Packages and Environments
  8. Classes and Objects
  9. Assertion
  10. Regular Expressions
  11. Sets
  12. Comprehensions
  13. Complex Numbers
  14. NumPy
  15. Working with Images
  16. Enumerate and Enum
  17. Map, Filter, and Reduce
  18. Working with Binary and Other Bases
  19. Visualisations and Plots
  20. Graphs and Graph Theory
  21. Creating and Visualising Graphs with NetworkX
  22. Defaultdict
  23. Recursion
  24. Caching and Dynamic Programming
  25. Exceptions
  26. Permutations, Combinations, Products and More
  27. Zip
  28. Unit Testing
  29. Eval and Literal Eval
  30. Priority Queues and Heaps
  31. Shortest Path Algorithms - BFS, Dijkstra, and A*
  32. LIFO, FIFO, and deques
  33. Useful Algorithms
  34. Interval and Range Algebra
  35. Cycle Detection and Modular Arithmetic
  36. Grid Geometry — Shoelace Formula and Pick's Theorem
  37. Cellular Automata and Sparse Grids
  38. Virtual Machines and Bytecode Decompilation
  39. Project Structure
  40. Using Colours
  41. Reusable Code
  42. My AoC Template, Version 3
  43. Modern Python Ergonomics for AoC
  44. Parsing with Parsimonious
  45. Jupyter Notebooks
  46. Encrypting Your Input
  47. Maths with SymPy
  48. Constraint Solving and Integer Optimisation