OFFSET
0,3
EXAMPLE
(a(0)+0) divides 6; (a(1)+1) divides 6; and (a(5)+5) divides 6. These 3 cases are the only cases where (a(k)+k) divides 6, for 0<=k<=5. So a(6)=3.
MATHEMATICA
f[l_List] := Block[{n = Length[l]}, Append[l, Count[Table[Mod[n, k - 1 + l[[k]]], {k, n}], 0]]]; Nest[f, {1}, 101] (* Ray Chandler, Jan 22 2007 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Leroy Quet, Jan 15 2007
EXTENSIONS
Extended by Ray Chandler, Jan 22 2007
STATUS
approved