A124108 Replace each 1 with 10 in binary representation of n.
0, 2, 4, 10, 8, 18, 20, 42, 16, 34, 36, 74, 40, 82, 84, 170, 32, 66, 68, 138, 72, 146, 148, 298, 80, 162, 164, 330, 168, 338, 340, 682, 64, 130, 132, 266, 136, 274, 276, 554, 144, 290, 292, 586, 296, 594, 596, 1194, 160, 322, 324, 650, 328, 658, 660, 1322, 336, 674
Offset: 0
Keywords
Links
Programs
-
Haskell
a124108 0 = 0 a124108 x = 2 * (b + 1) * a124108 x' + (b * 2) where (x', b) = divMod x 2 -- Reinhard Zumkeller, Mar 31 2015
-
Mathematica
Table[FromDigits[Flatten[IntegerDigits[n,2]/.(1->{1,0})],2],{n,0,60}] (* Harvey P. Dale, May 20 2021 *)
Extensions
Offset fixed by Reinhard Zumkeller, Mar 31 2015
Comments