OFFSET
1,3
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
MATHEMATICA
NestList[#+Max[1, DigitCount[#, 2, 0]]&, 0, 70] (* Harvey P. Dale, Apr 21 2016 *)
PROG
(Python)
a = 0
for n in range(100):
print a,
ta = a
c0 = (a==0)
while ta>0:
c0 += 1-(ta&1)
ta >>= 1
a += max(c0, 1)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Alex Ratushnyak, Aug 03 2012
STATUS
approved