OFFSET
0,4
COMMENTS
A variation on Hofstadter's G-sequence and Hofstadter-Conway $10000 sequence.
LINKS
Eric Weisstein's World of Mathematics, Hofstadter G-Sequence
Eric Weisstein's World of Mathematics, Hofstadter-Conway 10000-Dollar Sequence
MATHEMATICA
a[0] = 1; a[1] = 1; a[n_] := If[EvenQ[n], n/2 - a[a[n/2]], a[a[(n - 1)/2]] + a[(n - 1)/2 - a[(n - 1)/2]]]; Table[a[n], {n, 0, 85}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Ilya Gutkovskiy, May 27 2017
STATUS
approved