This branch has solutions for 2025, for other years see the other branches:
- Set up a Python virtual environment and install the dependencies with
uv install - Grab the cookie named "session" from adventofcode.com after you've signed in and put that in a file called .aoc-session
- Name your solution files like 01.py (zero-padded to 2 digits)
- Optionally
from aoc import *in your solutions to import the prelude - Either run the solutions directly (i.e.
python 01.py) or just run./aoc.pyand it will run today's solution
The input for the problem (a str) can be found in the data member of the aoc module. The input is cached so it's only requested once per day.
To manually specify which solution to run and the input to use, use the AOC_YEAR and AOC_DAY environment variables.