cp's OEIS Frontend

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.

A331834 Records of A038804: (Smallest prime > 10^n) - (largest prime < 10^n).

This page as a plain text file.
%I A331834 #25 Aug 18 2025 18:22:49
%S A331834 4,12,34,70,124,218,264,540,604,670,754,1182,1310,1418,2606,2702,3516,
%T A331834 4248,7358,7680,7692,9060,9962,17568,18052,23784,28218,29814,31024,
%U A331834 34788,41438,48984,59568,68986,75944,82700,83232,91840,113108,132652,153094,167608
%N A331834 Records of A038804: (Smallest prime > 10^n) - (largest prime < 10^n).
%e A331834 Smallest 2-digit prime is 11, largest 1-digit prime is 7, so 11 - 7 = 4 is a term; since there is no 0-digit prime, 4 is a(1).
%t A331834 Block[{s = ToExpression /@ Map[StringSplit, Drop[Import["https://oeis.org/A038804/b038804.txt", "Data"], 4]][[All, -1]]}, Union@ FoldList[Max, s]] (* _Michael De Vlieger_, Mar 14 2020, using b-file at A038804 *)
%t A331834 DeleteDuplicates[Table[NextPrime[10^n]-NextPrime[10^n,-1],{n,500}],GreaterEqual] (* The program generates the first 21 terms of the sequence. *) (* _Harvey P. Dale_, Aug 18 2025 *)
%o A331834 (PARI) d=0;for(k=1,500,my(t=10^k,dd=nextprime(t)-precprime(t));if(dd>d,print1(dd,", ");d=dd)) \\ _Hugo Pfoertner_, Mar 01 2020
%Y A331834 Cf. A038804.
%K A331834 nonn
%O A331834 1,1
%A A331834 _Robert G. Wilson v_, Jan 28 2020
%E A331834 a(37)-a(42) from _Giovanni Resta_, Mar 15 2020