login
a(n)=(floor(3*S2(n)/2)) mod 2, where S2(n) is the binary weight of n.
1

%I #5 Jan 08 2024 13:58:49

%S 0,1,1,1,1,1,1,0,1,1,1,0,1,0,0,0,1,1,1,0,1,0,0,0,1,0,0,0,0,0,0,1,1,1,

%T 1,0,1,0,0,0,1,0,0,0,0,0,0,1,1,0,0,0,0,0,0,1,0,0,0,1,0,1,1,1,1,1,1,0,

%U 1,0,0,0,1,0,0,0,0,0,0,1,1,0,0,0

%N a(n)=(floor(3*S2(n)/2)) mod 2, where S2(n) is the binary weight of n.

%t Table[Mod[Floor[(3*Total[IntegerDigits[n,2]])/2],2],{n,0,100}] (* _Harvey P. Dale_, Jan 08 2024 *)

%K easy,nonn

%O 0,1

%A _Ctibor O. Zizka_, Mar 02 2008