OFFSET
1,1
LINKS
J.W.L. (Jan) Eerland, Table of n, a(n) for n = 1..10000.
EXAMPLE
For k=4429, digitsum(k) = 4 + 4 + 2 + 9 = 19, digitsum(k+1) = 4 + 4 + 3 + 0 = 11.
MATHEMATICA
t=Table[0, {256}]; j=1; Do[s=Apply[Plus, IntegerDigits[n]]; s1=Apply[Plus, IntegerDigits[n+1]]; If[PrimeQ[s]&&PrimeQ[s1], Print[n]; t[[j]]=n; j=j+1], {n, 1, 10000}]; t
DeleteCases[ParallelTable[If[PrimeQ[Total[IntegerDigits[n]]]&&PrimeQ[Total[IntegerDigits[n+1]]], n, a], {n, 2, 952999}], a] (* J.W.L. (Jan) Eerland, Dec 20 2021 *)
PROG
(PARI) isok(n) = isprime(sumdigits(n)) && isprime(sumdigits(n+1)); \\ Michel Marcus, Jul 29 2017
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Labos Elemer, Mar 17 2004
STATUS
approved