Advent of Code 2024 Day 12 - 16th Gold Star!

preview_player
Показать описание
Advent of Code 2024, Day 12. I finished 205th for the first part and 16th for the second! Fun problem - I was pretty surprised how big my improvement in ranks was, but I'm guessing a lot of it is because LLMs just can't solve the second part (and maybe there's more of them on the leaderboard than I previously thought...).

0:00 - Intro
0:04 - Part 1
4:00 - Part 2
6:50 - Explanation
Рекомендации по теме
Комментарии
Автор

An elegant solution and a great explanation!

will_lynas
Автор

Nice tricks!! So enlightening! Advanced stuff, but amazing to learn from you! Thank you!

renanaraujom
Автор

For part 2 I ended up writing a new function that checks all side pieces in a certain direction by checking their adjacent directions (i.e. east and west are adjacent to north) and then repeating that for every other direction, which was more efficient than just rotating the entire grid but also more complicated. Also I got my best position ever (797 on part 2) so that kinda shows my level, lol.

Erwipro
visit shbcf.ru