Skip to content

logansquirel/advent_of_code

Repository files navigation

🎄 Advent of Code 🎅

Advent of Code is an annual Advent calendar of small programming puzzles for a variety of skill sets and skill levels that can be solved in any programming language you like.

Events

AoC-2015

AoC-2016

AoC-2017

AoC-2018

AoC-2019

AoC-2020

Solutions

CI

This repository is a collection of possible solution to each puzzle using the Rust programming language.

AoC-2015

AoC-2016

AoC-2017

AoC-2018

AoC-2019

AoC-2020

Usage

$ git clone https://github.com/logansquirel/advent_of_code.git
$ cd aoc_yyyy/day_dd
$ cargo run --quiet --release < input/input.dat
Advent of Code yyyy-dd
------ Part 1 ------
Answer 1

------ Part 2 ------
Answer 2
  • Replace yyyy with the four digits year
  • Replace dd with the two digits day (0-padded)
  • (Optional) Replace the path input/input.dat with the path to your personal puzzle input.

Template

This repository provides a Rust template (aoc_yyyy/day_dd) for advent of code.

$ tree aoc_yyyy
aoc_yyyy
└── day_dd
    ├── Cargo.toml              # Cargo configuration file
    ├── input
    │   └── input.dat           # Puzzle input
    ├── readme.md
    ├── src
    │   ├── lib.rs              # Puzzle solutions and unit tests
    │   └── main.rs             # Puzzle main
    └── tests
        └── aoc_yyyy_day_dd.rs  # Puzzle answers tests

4 directories, 6 files
  • Replace all yyyy occurences with the four digits year
  • Replace all dd occurences with the two digits day (0-padded)
  • Implement solution in lib.rs
  • Verify answers in aoc_yyyy_day_dd.rs

Questions, Issues, Contributing

For questions and issues, open an issue here.

Contributions and Pull Requests (PR) are welcome.

License

License

About

Advent of Code

Topics

Resources

License

Stars

Watchers

Forks

Contributors