OFFSET
1,1
EXAMPLE
(13 base 2) = 1101 -> 111.
PROG
(Python)
def ok(n):
b = bin(n)[2:]
if b == b[::-1]: return False
for skip in range(len(b)):
newb = b[:skip] + b[skip+1:]
if len(newb) > 0 and newb[0] == '1' and newb == newb[::-1]:
return True
return False
print(list(filter(ok, range(172)))) # Michael S. Branicky, Aug 24 2021
CROSSREFS
KEYWORD
nonn,base
AUTHOR
STATUS
approved