This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A217064 #21 Jul 30 2025 09:46:18 %S A217064 11,17,47,71,83,89,149,167,179,251,257,293,347,359,383,419,461,467, %T A217064 491,557,563,569,653,773,911,1193,1217,1277,1451,1559,1667,1823,1901, %U A217064 2243,2309,2357,2579,2657,2999,3527,3533,4289,5051,5351,5501,5843,6089,6551,6581 %N A217064 Primes that remain prime when a single "5" digit is inserted between any two adjacent decimal digits. %H A217064 Harvey P. Dale, <a href="/A217064/b217064.txt">Table of n, a(n) for n = 1..500</a> (First 140 terms from Paolo P. Lava) %e A217064 290183 is prime and also 2901853, 2901583, 2905183, 2950183 and 2590183. %p A217064 with(numtheory); %p A217064 A217064:=proc(q,x) %p A217064 local a,b,c,i,n,ok; %p A217064 for n from 5 to q do %p A217064 a:=ithprime(n); b:=0; while a>0 do b:=b+1; a:=trunc(a/10); od; a:=ithprime(n); ok:=1; %p A217064 for i from 1 to b-1 do %p A217064 c:=a+9*10^i*trunc(a/10^i)+10^i*x; if not isprime(c) then ok:=0; break; fi; od; %p A217064 if ok=1 then print(ithprime(n)); fi; od; end: %p A217064 A217064(1000000,5); %t A217064 Select[Prime[Range[5,1000]],AllTrue[FromDigits/@Table[ Insert[ IntegerDigits[ #],5,n],{n,2,IntegerLength[#]}],PrimeQ]&] (* _Harvey P. Dale_, Feb 20 2022 *) %o A217064 (PARI) is(n)=my(v=concat([""], digits(n))); for(i=2, #v-1, v[1]=Str(v[1], v[i]); v[i]=5; if(i>2, v[i-1]=""); if(!isprime(eval(concat(v))), return(0))); isprime(n) \\ _Charles R Greathouse IV_, Sep 26 2012 %Y A217064 Cf. A050674, A050711-A050719, A069246, A159236, A215417, A215419-A215421, A217044-A217047, A217062, A217063, A217065 %K A217064 nonn,base %O A217064 1,1 %A A217064 _Paolo P. Lava_, Sep 26 2012