proposed
approved
proposed
approved
editing
proposed
nonn,easy,base,more
approved
editing
editing
approved
Primes equal to a concatenate concatenation of a prime and a nonzero palindromic number.
proposed
editing
editing
proposed
(PARI) ispal(n) = n && (eval(subst(Polrev(digits(n)), x, 10)) == n);
isconc(n) = {d = digits(n); for (k=1, #d, na = n\10^k; nb = n % 10^k; if ((n == eval(concat(Str(na), Str(nb)))) && ((isprime(na) && ispal(nb)) || (isprime(nb) && ispal(na))), return(1)); ); }
isok(n) = isprime(n) && isconc(n); \\ Michel Marcus, Jun 20 2016
proposed
editing
editing
proposed
a2113(n)={my(d, i, r); r=vector(#digits(n-10^(#digits(n\11)))+#digits(n\11)); n=n-10^(#digits(n\11)); d=digits(n); for(i=1, #d, r[i]=d[i]; r[#r+1-i]=d[i]); sum(i=1, #r, 10^(#r-i)*r[i])}
proposed
editing
editing
proposed