OFFSET
1,1
EXAMPLE
966 is a term of the sequence because 966 in base 8 is 1706, its complement in base 8 is 6071 and the digit reverse is again 1706 that is 966 in base 10.
MAPLE
P:=proc(q, h) local a, b, k, n; for n from 1 to q do a:=convert(n, base, h); b:=0;
for k from 1 to nops(a) do a[k]:=h-1-a[k]; b:=h*b+a[k]; od; if b=n then print(n); fi; od; end: P(10^2, 8);
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
Paolo P. Lava, Apr 03 2017
STATUS
approved