Day 10. I lied about doing this later, I guess.
p1, 2 I accidentally solved 2. before 1.
My initial code was:
for every 9, mark that square with a score of 1. Then:
for (I = 8, then 7 ... 0) => mark the square with the sum of the scores of the squares around it with a value of i + 1.
Except that gives you all the ways to reach 9s from a 0, which is part 2. For part 1, I changed the scores to be sets of reachable 9s, and the score of a square was the size of the set at that position.