aoc-25/input/day7.txt
Jacob Jonsson d8824fd6bd feat: solve day 7
We parse the grid and then step through a simulation of the tachyon
beam's spread and count the number of splitters that the beam actually
hit.
2025-12-20 10:55:01 +01:00

142 lines
20 KiB
Text

......................................................................S......................................................................
.............................................................................................................................................
......................................................................^......................................................................
.............................................................................................................................................
.....................................................................^.^.....................................................................
.............................................................................................................................................
....................................................................^.^.^....................................................................
.............................................................................................................................................
...................................................................^.....^...................................................................
.............................................................................................................................................
..................................................................^.^.^.^.^..................................................................
.............................................................................................................................................
.................................................................^.^...^...^.................................................................
.............................................................................................................................................
................................................................^.^.^.^.^.^.^................................................................
.............................................................................................................................................
...............................................................^.^.^.^...^...^...............................................................
.............................................................................................................................................
..............................................................^.^.....^.^...^.^..............................................................
.............................................................................................................................................
.............................................................^...^.....^.^.^.^.^.............................................................
.............................................................................................................................................
............................................................^...^.^.^.^...^.^.^.^............................................................
.............................................................................................................................................
...........................................................^.^.^.^...^...^.^...^.^...........................................................
.............................................................................................................................................
..........................................................^.^.^...^.^.^...^.^.^...^..........................................................
.............................................................................................................................................
.........................................................^.^...^.^.^.^.^.^.^.^.^.^.^.........................................................
.............................................................................................................................................
........................................................^.^...^.^.^.^.^.......^...^.^........................................................
.............................................................................................................................................
.......................................................^...^.^...^.^.......^.^...^.^.^.......................................................
.............................................................................................................................................
......................................................^...^.^...^.^...^.^...^.^.^.....^......................................................
.............................................................................................................................................
.....................................................^.^.^.^.^.^...........^.^...^.^...^.....................................................
.............................................................................................................................................
....................................................^.^.^...^.^.^.^.^.^.^...^.^.....^.^.^....................................................
.............................................................................................................................................
...................................................^.^.^.^...^.....^.........^...^...^.^.^...................................................
.............................................................................................................................................
..................................................^.^.^...^...^.^.^...^.^.^.^...^.^.....^.^..................................................
.............................................................................................................................................
.................................................^.^...^.^.^...^...^...^...^.^.^.^.^...^.^.^.................................................
.............................................................................................................................................
................................................^.^.^...........^.^.^.^.^.^.....^.^.^.....^.^................................................
.............................................................................................................................................
...............................................^.^.^.^.^.^.^.^.^.^.^...^.^.^.^.^.^.^.^.^.^.^.^...............................................
.............................................................................................................................................
..............................................^...^.^.^.^...^...^.^.^.....^...^.^.^...^.^.^.^.^..............................................
.............................................................................................................................................
.............................................^.^.^.^.....^.^.^.^.^...^.^.^.^.^...^.^...^...^.^.^.............................................
.............................................................................................................................................
............................................^.^.^.^.^.^.....^.^.^...^.^.....^.^.^.....^.^...^...^............................................
.............................................................................................................................................
...........................................^.^.^...^.^.^.^...^.^.^.^.^.......^.^.^.^.^.^...^...^.^...........................................
.............................................................................................................................................
..........................................^.^.^.^...^.^.^.^.^.^.^.^...^.....^...^.^.^...^.^...^.^.^..........................................
.............................................................................................................................................
.........................................^.....^.^.^.^...^.^.^.....^.^.^.^.^.....^.^.^.^.^.^.^.^.^.^.........................................
.............................................................................................................................................
........................................^.^.^...^.....^...^.....^.^.^...^.^.^.^...^.^.^.^...^.^.^.^.^........................................
.............................................................................................................................................
.......................................^.^.^.........^...^...^...^.^.^.^...^.^.^.^...^.^.^.^.^...^...^.......................................
.............................................................................................................................................
......................................^.^...^.^.^...^.^.^.^.^.^...^...^.^.^...^.^.^.^...^.....^.......^......................................
.............................................................................................................................................
.....................................^...^.^.^.^.^.^.^.^.^.^.^.^.^...^...........^.^.^.^...^.....^.^.^.^.....................................
.............................................................................................................................................
....................................^.^.^.......^.^...^...^...^.....^.......^.^...^.......^.^.^.^...^.^.^....................................
.............................................................................................................................................
...................................^.^.^.^.^.^.....^.^...^.^.^.^.^...^.^.^...^.^.^.^.^...^...^.^.^.^.^.^.^...................................
.............................................................................................................................................
..................................^.^...^.^.^.^...^.....^...^.......^.^.^.^.^.^.^...^.^...^.^.....^.^.^.^.^..................................
.............................................................................................................................................
.................................^.^.^.^.^.^.^...^.^.....^.^.^.........^.^...^.^...^.....^.^.^.^.^.^...^.^.^.................................
.............................................................................................................................................
................................^...^.^.....^...^.^.^.^...^.^...^.^.^...^...^.^.^.^.^.^.^.....^.^.^...^.....^................................
.............................................................................................................................................
...............................^.....^...^...^.^.^...^.^.......^.^.^...^.^.^...^.^.^.^...^.^.^.^.^.^.....^...^...............................
.............................................................................................................................................
..............................^.^.^...^...^.....^.^.^.^.^.^...^.^...^...^...^.^.^.^.^.^.^...^.^.^.^...^.^.....^..............................
.............................................................................................................................................
.............................^.^.^.^...^.^...^.^...^...^.^...^.^.^.^...^.....^...^.^.^.......^.^.^...^...^.....^.............................
.............................................................................................................................................
............................^.....^...^...^.^.^.^.^.....^.^.^.^.^.......^.^.^.........^...........^.^.^...^.....^............................
.............................................................................................................................................
...........................^.^.^...^...^.^.....^.^.^.^.^.^.^.^.....^.^.^.^.^.^.^...^.....^.^...^.^.....^.^.^.^...^...........................
.............................................................................................................................................
..........................^.^.^.^.^...^.^.........^.^.^.^.....^...^.^.....^.^.^.^.^.^...^.....^...^.^.^.^...^.....^..........................
.............................................................................................................................................
.........................^...^.^...^.^.^.^...^...^...^...^.^...^.^.^.^.^.^.^...^.^.^.^...^.^.^.^.^.^...^.....^...^.^.........................
.............................................................................................................................................
........................^.^.^...^.^.^.......^...^.^.^.^.^.^...^.^.^...^...^.^.^...^.^.^...^.^.^.^...^...^.^.^.^.^.^.^........................
.............................................................................................................................................
.......................^...^...^.^.^.....^.^.....^.....^.^.^...^.^.......^.^.^.....^...^.^.....^.^.^.^.....^.^.^...^.^.......................
.............................................................................................................................................
......................^.......^.^.^...^.^...^.^...^.^.^.^.....^.^.^.^.^...^.^.^.^.^.^.....^.^.^.^.^.^.^.^.^.....^.^...^......................
.............................................................................................................................................
.....................^.^.^.^.^.^.^.^.^...^.^.^.^.....^.^.^.^.^.^.^.^.^.^.^.^.^...^.^.^...^.^.^...^.^.^.^.^.^.^...^.^.^.^.....................
.............................................................................................................................................
....................^.^...^.....^.^.^.^...^.^.^...^.^.^.^...^.^...^.^.^.....^.....^.^.^...^.^.^...^...^...^.^...^.^...^.^....................
.............................................................................................................................................
...................^.^.^.^.^.^.^...^.^...^.^.^.^...^.^.^.^.....^...^.^.^.^...^.^.^.^.^.^.......^.^...^.^.^.^.....^.^...^.^...................
.............................................................................................................................................
..................^.^.^...^.^...^...^.^.^.........^...^.^.^.^.^.^.^.^.^.^.....^.^...^...^.^.^.......^...^.....^...^.^.^...^..................
.............................................................................................................................................
.................^.^.^.^...^.^.^...^...^...^...^.^.^.^.......^.^.^.^.....^...^.^.^.^...^.^...^.^...^.....^.^.^.^.^.^.......^.................
.............................................................................................................................................
................^.^.....^...^.^.^...^.......^.^.^.^...^.^...^.^.^.^.^.^.^.......^...^...^...^...^.^...^...^...^...^.^.^.^.^.^................
.............................................................................................................................................
...............^.^.....^.....^.^.^.^.^.^...^.^...^.^.^.^.....^.^.^.^.^...^...^.^.^.......^.^.^.^.^...^.^...^...^.^.^.^.^.^...^...............
.............................................................................................................................................
..............^.^...^...^...^.^.^...^...^...^...^.^...^.^.^.^.^...^.^.^.^.^.^.^.^...^.^.......^.....^.........^.^.^.^.^.^.^.^.^..............
.............................................................................................................................................
.............^.^.^.^.^...^.^.^.^.^.^.^.^.^...^.^.^.^.^.^.^.^.^.^...^.^.^.^.^.^...^.^.^.^.......^...^.^...^.^.^.^.^.....^.^.^...^.............
.............................................................................................................................................
............^.....^.^.^.^.^.^.^.^.^.....^.^...^...^...^.^.^.^.........^.^.^.....^...^.^...^.^.^.....^.^.^.^.^...^.....^.^.^...^.^............
.............................................................................................................................................
...........^.....^.^...^.^...^.^.^.^...^...^...^.^.^.^.^.^.^.^.^.^.^.^.^.^.^...^.^.^.^.^.^.^.^.......^.^.^.^.^...^.^.^.^.....^.^.^...........
.............................................................................................................................................
..........^...^.^...^.^.^.^.^.^.^...^.^...^.^.^...^...^.^.^.....^.^.^.......^.^.^.^...^.^.^...^.^.^.^.^.^...^.^.....^...^...^.^...^..........
.............................................................................................................................................
.........^.^.^.^...^.^.^.....^.^...^.^.......^.^.....^.^.^.^.^.....^.^...^...^.^.^.......^.^.^.^.^...^.......^.^...^.^...^.^.^...^.^.........
.............................................................................................................................................
........^.^.....^.....^.^...^.^.....^.^...^.....^.^...^.^...^.^...^...^...^.^...^.^.^...^...^.^.....^.^.^.^.^.^.^...^.^.^.^...^.^.^.^........
.............................................................................................................................................
.......^.^.^...^.^.^.^.^...^...^...^.^.^.^.^.....^.^.^.^.^.^.^.^...^.^.^.^.^.^...^.^...^.^.......^.^.^.....^.^.^.^.^...^.....^.^...^.^.......
.............................................................................................................................................
......^.^.....^.^...^.^.^.^.^.....^...^...^.....^.^...^.^.......^.^.^.......^.....^.^.^.^.^.^.^.^.^.^...^.^.^.^.^.^...^...^.^...^.^.^.^......
.............................................................................................................................................
.....^.^.^.^.^...^...^.^.^...^.^.....^.^...^.......^.^.^...^.^...^.^.^.^.....^...^.^.^...^.^.^.^.....^.^.^.....^...^.^.^.^.^.^.^.^.^...^.....
.............................................................................................................................................
....^.^.^.^.^.^.^.^.^.........^.^...^.^.^.^.^.^.^.^.^...^.^.^...^.^.^.^.^.^...^.^.^.^.^.^...^.^.^...^.^.^...^...^.^...^.^.^.^.^.^...^.^.^....
.............................................................................................................................................
...^...^.....^...^.^.^.^.^...^.....^...^.^...^.^.^.^.^.^...^.^...^.^.^...^.^.^.^.^...^.^.^.^...^.^.^.^.^.^.^.........^.^...^.^.^.^.^.^.^.^...
.............................................................................................................................................
..^.....^.^.......^.^.^.^.^.^.^.^...^.^.^...^.^.^.^.^.^.^.^...^.^.^...^.^.^.^.....^.^.^...^.....^.^.^...^.^.^.^.........^.^.....^.....^.^.^..
.............................................................................................................................................
.^.^.^...^.^...^.^.^...^...^...^.....^.^...^.^...^.^.^...^...^.^...^...^.....^.....^.^.^...^.^.^.....^...^...^.^.^.^.^.^.....^.^.^.......^.^.
.............................................................................................................................................