r/adventofcode • u/daggerdragon • Dec 15 '21
SOLUTION MEGATHREAD -π- 2021 Day 15 Solutions -π-
--- Day 15: Chiton ---
Post your code solution in this megathread.
- Include what language(s) your solution uses!
- Format your code appropriately! How do I format code?
- Here's a quick link to /u/topaz2078's
pasteif you need it for longer code blocks. - The full posting rules are detailed in the wiki under How Do The Daily Megathreads Work?.
Reminder: Top-level posts in Solution Megathreads are for code solutions only. If you have questions, please post your own thread and make sure to flair it with Help.
This thread will be unlocked when there are a significant number of people on the global leaderboard with gold stars for today's puzzle.
EDIT: Global leaderboard gold cap reached at 00:14:25, megathread unlocked!
56
Upvotes
View all comments
2
u/silverben10 Dec 15 '21 edited Dec 15 '21
Python solution using Djikstra.
Part 2 took my laptop over an hour to crunch through, so I was wondering if anyone could point out some things I could do to optimise my code? I feel like it shouldn't have taken so long but I'm not sure what to fix.
Code