OFFSET
1,2
PROG
(Python)
from operator import mul
from functools import reduce
from gmpy2 import t_mod, digits, mpz
A246337 = sorted([mpz(n, 16) for n in (digits(x, 16)+digits(x, 16)[::-1]
....for x in range(1, 16**7)) if not (n.count('0') or
....t_mod(mpz(n, 16), sum((mpz(d, 16) for d in n)))
....or t_mod(mpz(n, 16), reduce(mul, (mpz(d, 16) for d in n))))] +
....[mpz(n, 16) for n in (digits(x, 16)+digits(x, 16)[-2::-1]
....for x in range(16**7)) if not (n.count('0') or
....t_mod(mpz(n, 16), sum((mpz(d, 16) for d in n)))
....or t_mod(mpz(n, 16), reduce(mul, (mpz(d, 16) for d in n))))])
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Chai Wah Wu, Aug 22 2014
STATUS
approved