OFFSET
1,1
MATHEMATICA
Array[a, 500]; Do[a[n] = 0, {n, 1, 500}]; n = 9; ct = 0; While[ct < 150, m = 3; While[ ! (PrimeQ[m] && (((n - m)/2) > 2) && PrimeQ[(n - m)/2]), m = m + 2]; k = PrimePi[m]; If[a[k] == 0, a[k] = n; ct = ct + 1]; n = n + 2]; Print[a]
PROG
CROSSREFS
KEYWORD
nonn,hard
AUTHOR
Lei Zhou, Feb 10 2005
EXTENSIONS
Edited and Scheme-code added by Antti Karttunen, Jun 19 2007
STATUS
approved