~reesmichael1/adventofcode

Solutions for the Advent of Code puzzles
Use neighbors function instead of duplicating code
Add solution for day 16
Move some imports into the isMainModule block

refs

master
browse log

clone

read-only
https://git.sr.ht/~reesmichael1/adventofcode
read/write
git@git.sr.ht:~reesmichael1/adventofcode

You can also use your local clone with git send-email.

Advent of Code 2019 Solutions

These solutions are written in Nim.

Task Runner

I had some fun with Nim metaprogramming and built a task runner that will automatically load any solution files in the src directory at compile time. (After all, what's the fun in doing something simply and straightforwardly without overengineering?) To use it:

nimble build
./bin/runner  # The solutions do not handle relative paths

The runner will notify you if the files in the src directory do not match those that have been compiled into it.

Helper Functions

The input module has some helper functions to access the input data. Any input files should be put in an input directory at the top of the repository with the name dayN.