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 A094786 #11 Aug 25 2025 11:20:30 %S A094786 2,7,23,47,79,167,223,241,359,439,727,839,1087,1223,1367,1847,2207, %T A094786 2399,3023,3373,3719,3967,4759,5039,5623,5927,6857,7919,8647,10607, %U A094786 11447,13687,14159,14639,16127,17159,18223,19319,19681,21023,24023,25919 %N A094786 Primes that are 2 less than a perfect power m^k, k >= 2. %H A094786 Zak Seidov, <a href="/A094786/b094786.txt">Table of n, a(n) for n = 1..1000</a> %t A094786 perfPQ[n_]:=GCD@@FactorInteger[n][[All,2]]>1; Select[Prime[Range[3000]],perfPQ[#+2]&] (* _Harvey P. Dale_, Aug 25 2025 *) %o A094786 (PARI) k(n,m) = forprime(x=2,n,if(ispower(x+m),print1(x","))) ispower(n) = { local(p,r,j); r = sqrt(n); for(j=2,floor(r), p = floor(log(n)/log(j)+.5); if(j^p ==n,return(1)); ); return(0) } %Y A094786 Cf. A001597 (perfect powers). %K A094786 nonn,changed %O A094786 1,1 %A A094786 _Cino Hilliard_, Jun 10 2004 %E A094786 Comment deleted by _Zak Seidov_, Apr 17 2013