Discussion thread for day 3 of the Advent of Code - https://adventofcode.com/2023/day/3
This one was interesting. I found it more challenging then day 1 or 2. Great to see all the approaches here, of the half dozen ways I tried I never even considered generate rows!!
My solution.
Hard coded some stuff but it works I guess! Forgot that REGEX_CountMatches exists when I started…
Also, special credit to @clmc9601 ! Her guide and previous AOC entry really helped me conceptualise this better. I added a comment to visualise the “surrounding” values of the special characters! Thanks Claire!!!!
It took me 30 min of troubleshooting to figure out my workflow was fine, but I had to turn AMP engine off.
Not so pretty flow but get the number correctly. 😁
I definitely had a flashback to previous years of AOC when reading the prompt for this one! Keeping the data long and thin and making use of IDs was the key to helping me wrap my head around how to solve this one without over complicating it.
For sure can be optimized but don't want to spend more time here XD