OFFSET
0,2
COMMENTS
Subsequence of A057148.
a(n) is a multiple of 11.
FORMULA
EXAMPLE
MATHEMATICA
Array[FromDigits@ Join[#, Reverse[#]] &@ IntegerDigits[#, 2] &, 26, 0] (* Michael De Vlieger, Feb 26 2021 *)
PROG
(Ruby)
def A(n)
str = n.to_s(2)
(str + str.reverse).to_i
end
def A342036(n)
(0..n).map{|i| A(i)}
end
p A342036(30)
(Python)
def a(n): b = bin(n)[2:]; return int(b+b[::-1])
print([a(n) for n in range(27)]) # Michael S. Branicky, Feb 26 2021
CROSSREFS
KEYWORD
nonn,easy,base
AUTHOR
Seiichi Manyama, Feb 26 2021
EXTENSIONS
Offset changed to 0 by Andrey Zabolotskiy, Dec 26 2022
STATUS
approved