Toot

Written by Sebastian Lauwers on 2024-12-06 at 23:00

@felyashono don’t know if you read Rust, but here’s my solution: https://github.com/teotwaki/aoc/blob/main/2024/06/src/lib.rs

In essence, I have a hashmap with the locations of the obstacles and a hashset of visited locations/direction combo. The hashset is used to detect loops. I add one obstacle on every location along the path and simulate the route again. I remove some path locations as possible candidates by checking if they would send out of bounds.

=> More informations about this toot | View the thread | More toots from teotwaki@mastodon.online

Mentions

=> View felyashono@disabled.social profile

Tags

Proxy Information
Original URL
gemini://mastogem.picasoft.net/toot/113608362415985990
Status Code
Success (20)
Meta
text/gemini
Capsule Response Time
227.905289 milliseconds
Gemini-to-HTML Time
0.554119 milliseconds

This content has been proxied by September (3851b).