summaryrefslogtreecommitdiff
path: root/20.c
AgeCommit message (Collapse)Author
2023-01-19Puzzle 20: Do a linear scan for the num we're looking forAdam Spragg
When the number of iterations was small, looking near the original position of the num was a good idea. As the number of iterations increases, the positions are fairly random, so speed of lookup is mostly a factor of how quickly we can scan the whole buffer. Speeds up part 2 of the problem from 2.2s to 0.12s.
2022-12-20Solve puzzle 20 part 2Adam Spragg
Phew. Nice easy one for today! Caught up now.
2022-12-20Solve puzzle 20 part 1Adam Spragg