This repository contains the puzzles and my solutions for the popular Advent of Code online programming puzzle tournament:
2015 • 2016 • 2017 • 2018 • 2019 • 2020 • 2021 • 2022 • 2023
My solutions are mostly written in Python 2.7 (or 3.9+ since 2023), with the occasional C implementations where Python's performance is problematic. In both cases, the solutions are attempts at code golf, so please don't expect any well-commented, easily understandable, extensible code here! The following exceptions are made:
- The code is still meant to be reasonably efficient in terms of runtime performance.
- The name of the input file is
input.txt
, not just a single letter. - Dimensions are only hard-coded when a flexible solution is significantly longer or more complex.
- C code is "self-compiling" when marked executable on Unix (i.e. it compiles and runs itself, making the C program more or less behave like a script).
- A "she-bang" is however not included for Python files.
- C code uses the occasional line break where it's not strictly necessary to make it at least a tiny bit readable.