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 A077715 #19 Jun 23 2022 15:42:12 %S A077715 7,17,317,6317,26317,126317,2126317,72126317,372126317,5372126317, %T A077715 305372126317,9305372126317,409305372126317,20409305372126317, %U A077715 100020409305372126317,9100020409305372126317,209100020409305372126317,40209100020409305372126317 %N A077715 a(1) = 7; thereafter a(n) = the smallest prime of the form d0...0a(n-1), where d is a single digit, or 0 if no such prime exists. %C A077715 a(n) is the smallest prime obtained by prefixing a(n-1) with a number of the form d*10^k where d is a single digit, 0 < d < 10, and k >= 0. Conjecture: d*10^k always exists. %H A077715 Michael S. Branicky, <a href="/A077715/b077715.txt">Table of n, a(n) for n = 1..50</a> %p A077715 a:= proc(n) option remember; local k, m, d, p; %p A077715 if n=1 then 7 else k:= a(n-1); %p A077715 for m from length(k) do %p A077715 for d to 9 do p:= k +d*10^m; %p A077715 if isprime(p) then return p fi %p A077715 od od %p A077715 fi %p A077715 end: %p A077715 seq(a(n), n=1..20); # _Alois P. Heinz_, Jan 12 2015 %o A077715 (Python) %o A077715 from sympy import isprime %o A077715 from itertools import islice %o A077715 def agen(an=7): %o A077715 while True: %o A077715 yield an %o A077715 pow10 = 10**len(str(an)) %o A077715 while True: %o A077715 found = False %o A077715 for t in range(pow10+an, 10*pow10+an, pow10): %o A077715 if isprime(t): %o A077715 an = t; found = True; break %o A077715 if found: break %o A077715 pow10 *= 10 %o A077715 print(list(islice(agen(), 18))) # _Michael S. Branicky_, Jun 23 2022 %Y A077715 Cf. A053584, A077713, A077714, A077716. %K A077715 base,nonn %O A077715 1,1 %A A077715 _Amarnath Murthy_, Nov 19 2002 %E A077715 More terms from _Ray Chandler_, Jul 23 2003 %E A077715 Definition clarified by _N. J. A. Sloane_, Jan 19 2015