%I #12 Jan 07 2019 11:12:35
%S 0,1,0,1,0,2,0,1,0,2,0,3,0,1,0,1,0,2,0,3,0,1,0,2,0,1,0,1,0,2,0,1,0,2,
%T 0,3,0,1,0,2,0,1,0,1,0,2,0,3,0,1,0,1,0,2,0,1,0,3,0,2,0,1,0,1,0,2,0,3,
%U 0,1,0,2,0,1,0,1,0,2,0,3,0,1,0,1,0,2,0,1,0,3,0,2,0,1,0,2,0,1,0,1,0,2,0,1,0
%N Number of iterations of A011371(x) = x - A000120(x) needed to reach an odd number, when starting from x = n.
%C Terms 0 .. 10 occur for the first time at n = 1, 2, 6, 12, 126, 192, 486, 492, 498, 504, 65458.
%H Antti Karttunen, <a href="/A322983/b322983.txt">Table of n, a(n) for n = 1..65537</a>
%H <a href="/index/Bi#binary">Index entries for sequences related to binary expansion of n</a>
%F If n is odd, a(n) = 0, if n is even, a(n) = 1 + a(A011371(n)).
%o (PARI) A322983(n) = if((n%2),0,1+A322983(n - hammingweight(n)));
%Y Cf. A000120, A011371, A071542, A179016, A213710, A322984 (bisection).
%Y Cf. also A322996.
%K nonn,base
%O 1,6
%A _Antti Karttunen_, Jan 05 2019