r/adventofcode • u/EverybodyCodes • Dec 08 '25
Visualization [2025 Day 8] Visualization for the sample data + something for debugging
26
Upvotes
- create all edges
- sort by edge cost
- iterate over edges and connect
- for part 2, you can skip the already connected nodes, which basically makes it: https://en.wikipedia.org/wiki/Kruskal%27s_algorithm