OFFSET
0,6
LINKS
Antti Karttunen, Table of n, a(n) for n = 0..65537
FORMULA
MATHEMATICA
f[n_] := Which[n == 1, 0, OddQ@ #, 0, EvenQ@ #, 1 + f[#/2]] &@ Fold[BitXor, n, Quotient[n, 2^Range[BitLength@ n - 1]]]; Accumulate@ Array[f, {85}] (* Michael De Vlieger, Feb 12 2016, after Jan Mangaldan at A006068 *)
PROG
CROSSREFS
Cf. also A054861.
KEYWORD
nonn
AUTHOR
Antti Karttunen, Feb 10 2016
STATUS
approved