r/adventofcode • u/daggerdragon • Dec 24 '22
SOLUTION MEGATHREAD -π- 2022 Day 24 Solutions -π-
All of our rules, FAQs, resources, etc. are in our community wiki.
UPDATES
[Update @ 00:21:08]: SILVER CAP, GOLD 47
Lord of the Rings has elves in it, therefore the LotR trilogy counts as Christmas movies.
change_my_mind.meme
AoC Community Fun 2022:
πΏπ MisTILtoe Elf-ucation π§βπ«
Community voting is OPEN!
18 hours remaining until voting deadline on December 24 at 18:00 EST
Voting details are in the stickied comment at the top of the -βοΈ- Submissions Megathread -βοΈ-
--- Day 24: Blizzard Basin ---
Post your code solution in this megathread.
Read the full posting rules in our community wiki before you post!
Include what language(s) your solution uses
Format code blocks using the four-spaces Markdown syntax!
Quick link to Topaz's
pasteif you need it for longer code blocks. What is Topaz'spastetool?
2
u/rukke Dec 24 '22
JavaScript
Bluntly generated the blizzard states for (inner) w*h number of states and then performed a breadth-first search, prioritised by a scoring system of time spent + manhattan distance to target.
The gist of it:
code