Consider the decimal expansion of 1/998998999:
0.000000001001002 004007013024…
Notice that those numbers in units of three digits - let's call them {an} - satisfy an=an−1+an−2+an−3.
If a1=a2=1 and a3=2, find the least n for which the recurrence is no longer satisfied.
Inspired by this problem.