#AdventOfCode 2024 day 1, in #RustLang in some 30-ish lines of code.

AOC always starts off gentle, and this is no exception. Can be coded in a couple minutes.

This is the first year where I’m using my new AOC workbench, which gives me the opportunity to share data structure/algorithms between years/days, and compiles everything in a single binary.

https://github.com/teotwaki/aoc/blob/main/2024/01/src/lib.rs

aoc/2024/01/src/lib.rs at main · teotwaki/aoc

Contribute to teotwaki/aoc development by creating an account on GitHub.

GitHub

#AdventOfCode 2024 day 2, in #RustLang in about 50-ish lines of code.

Step 1 was easy, step 2 was easy to understand, but a bit harder to express elegantly. Not sure I succeeded :).

https://github.com/teotwaki/aoc/blob/main/2024/02/src/lib.rs

#AOC2024

aoc/2024/02/src/lib.rs at main · teotwaki/aoc

Contribute to teotwaki/aoc development by creating an account on GitHub.

GitHub

#AdventOfCode 2024 day 3, in #RustLang in about 35-ish lines of code.

This one was fun. I always like @ericwastl's parsing challenges.

https://github.com/teotwaki/aoc/blob/main/2024/03/src/lib.rs

#AOC2024

aoc/2024/03/src/lib.rs at main · teotwaki/aoc

Contribute to teotwaki/aoc development by creating an account on GitHub.

GitHub

#AdventOfCode 2024 day 4, in #RustLang.

We're back to the coordinate system and a good old grid. I implemented a generic grid that I'm hoping to re-use in past challenges as well. I also massively extended the generic Coordinates struct. I'd say step2 was significantly easier than step1.

https://github.com/teotwaki/aoc/blob/main/2024/04/src/lib.rs

#AOC2024

aoc/2024/04/src/lib.rs at main · teotwaki/aoc

Contribute to teotwaki/aoc development by creating an account on GitHub.

GitHub
@teotwaki I also made a grid type last year and it's pretty helpful today
https://github.com/LesleyLai/AOC2024/blob/main/day4/src/main.rs
AOC2024/day4/src/main.rs at main · LesleyLai/AOC2024

Contribute to LesleyLai/AOC2024 development by creating an account on GitHub.

GitHub