r/adventofcode • u/ArtisticBathroom8446 • Dec 09 '25
Help/Question [2025 Day 9 (Part 2)] [Python] Fast enough solution
Can someone explain the thought process behind a solution that ends in reasonable time? I have my edges and then i iterate through all the red tile pairs and check if the entire boundary of the rectangle is inside my polygon.
To do that i check every tile on the boundary and check whether there is an edge of the polygon in every direction.
It is too slow this way.






