Skip to content

Latest commit

 

History

History
137 lines (115 loc) · 12.5 KB

README.md

File metadata and controls

137 lines (115 loc) · 12.5 KB

These are my solutions to Advent of Code 2023 for years 2022, 2023, 2024 (ongoing). They are all coded in Java, needing Java 21 at least.

To run Day 21 of 2024, say, you must build with a puzzle input in src/advent2024/puzzle21.txt.

Index

2022

2023

2024

Acknowledgements

All solutions are entirely the work of Éamonn McManus except as noted below.

  • 2022-12-16 (opening valves and traversing tunnels).

    My original solution was very inefficient and I was able to make it much faster using an idea from Martijn Pieters (zopatista) on [Reddit] (https://www.reddit.com/r/adventofcode/comments/zo21au/2022_day_16_approaches_and_pitfalls_discussion/).

  • 2023-12-17 (least-cost path with constraints on moves)

    I gave up before finding the right Dynamic Programming approach. I ended up copying my approach from David Brownman.

  • 2023-12-20 (pulse propagation)

    I had a strong suspicion of what the right approach might be for Part 2 but would have needed to investigate in detail to confirm. Instead I looked online and found this description by Dazbo, which confirmed my suspicion. Then solving was straightforward.

  • 2023-12-21 (counting paths in an infinite graph)

    I was not really motivated to put in the work for Part 2 so I outright cheated, by copying this solution by Michiel Graat.

  • 2023-12-24 (intersections of 3-dimensional lines)

    This curious puzzle was entirely solvable with algebra, the computer only serving to solve simultaneous equations. I did the first part myself, but did not find the right approach for the second part on my own. The excellent explanation and solution by @dirk527 showed me the right path, but then there wasn't much for me to write.

  • 2024-12-15 (robot pushing stacks of boxes).

    I found this very tricky to get right. In order to track down a bug, I compared the output from my solution with the output from the solution by Balázs Zaicsek (which I picked because it was in Java).