OFFSET
0,3
LINKS
Antti Karttunen, Table of n, a(n) for n = 0..9996
MATHEMATICA
Table[Table[n, {-1 + Length@ NestWhileList[# - Block[{m = #, c = 1}, While[a = (# - Floor[Sqrt@ #]^2) &@ m; a != 0, c++; m = a]; c] &, ((n + 1)^2) - 1, # != n^2 - 1 &]}], {n, 0, 18}] // Flatten (* Michael De Vlieger, Sep 08 2016 *)
PROG
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Sep 07 2016
STATUS
approved