OFFSET
1,1
EXAMPLE
110651 is in the list as its upside-down form 110921, and its emirp 156011, and the emirp of its upside-down form 129011, are all primes and uniquely different numbers.
PROG
(Python)
from sympy.ntheory import isprime as isp
def ip(pp):
rr = []
for qq in pp:
if qq=="0" or qq=="1" or qq=="8":
rr.append(qq)
elif qq=="2":
rr.append("5")
elif qq=="5":
rr.append("2")
elif qq=="6":
rr.append("9")
elif qq=="9":
rr.append("6")
return "".join(rr)
for bb in range(1, 10000000):
if isp(bb):
bb = str(bb)
if ("7" not in bb) and ("4" not in bb) and ("3" not in bb):
cc = bb[::-1]
dd = ip(bb)
ee = ip(cc)
if bb!=cc and dd!=ee and bb!=dd and bb!=ee and cc!=dd and cc!=ee and isp(int(cc)) and isp(int(dd)) and isp(int(ee)):
print(bb)
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Ray G. Opao, Jun 20 2020
STATUS
approved