This repository contains my solutions for Advent of Code challenges implemented in Golang.
The repository is organized by year, with each year containing the solutions for each day:
aoc2023/
: Solutions for Advent of Code 2023.day1/
: Contains the solution for Day 1.day2/
: Contains the solution for Day 2. ...
Each day's directory typically includes:
input.txt
: The input data for the specific day.main.go
: The Golang code implementing the solution.
-
Clone the repository:
git clone https://github.com/10wpressure/advent-of-code.git
To simplify the process of downloading Advent of Code input data, you can use the Advent of Code downloader CLI utility. Follow the instructions below to set it up:
-
Install the downloader using
go get
:go install github.com/GreenLightning/advent-of-code-downloader/aocdl@latest
-
Set your session cookie as a command line parameter:
aocdl -session-cookie 0123456789...abcdef
Or create a configuration file named .aocdlconfig in your home directory or in the current directory and add the session-cookie key:
bash { "session-cookie": "0123456789...abcdef" }
3. Navigate to your current problem (i.e. cd aoc2023/day3) and use command:
```bash
aocdl -year 2015 -day 1