After cloning the repo (git clone
) and installing the dependencies (npm install
), simply run npm start
to start the program.
To create a solution for a certain day, you'll need to create two files in the /solutions
directory (create the directory if it doesn't exist). One will be the solution itself and the other will be the puzzle input.
Example for setting up day 1:
export function partOne(input) {
// solution goes here
}
export function partTwo(input) {
// solution goes here
}
9cbncbxclbvkmfzdnldc
jjn1drdffhs
3six7
38rgtnqqxtc
rxszdkkv3j8kjhbm
...
The solution file should have two named exports partOne
and partTwo
. These functions will be called with the puzzle input as the first parameter.