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.

A068105 Smallest prime starting with n 5s.

This page as a plain text file.
%I A068105 #9 Feb 05 2021 16:46:48
%S A068105 2,5,557,5557,555521,555557,55555517,55555553,5555555501,5555555557,
%T A068105 555555555551,555555555551,5555555555551,555555555555529,
%U A068105 555555555555557,55555555555555519,555555555555555559,555555555555555559,55555555555555555567,5555555555555555555087
%N A068105 Smallest prime starting with n 5s.
%H A068105 Michael S. Branicky, <a href="/A068105/b068105.txt">Table of n, a(n) for n = 0..1000</a>
%F A068105 a(n) <= A065588(n). - _Michael S. Branicky_, Feb 05 2021
%o A068105 (Python)
%o A068105 from sympy import isprime
%o A068105 def a(n):
%o A068105   if n < 2: return list([2, 5])[n]
%o A068105   n5s, i, pow10 = int('5'*n), 1, 1
%o A068105   while True:
%o A068105     i = 1
%o A068105     while i < pow10:
%o A068105       t = n5s * pow10 + i
%o A068105       if isprime(t): return t
%o A068105       i += 2
%o A068105     pow10 *= 10
%o A068105 print([a(n) for n in range(20)]) # _Michael S. Branicky_, Feb 05 2021
%Y A068105 Cf. A065584, A068103, A068104, A065587, A065588.
%K A068105 base,easy,nonn
%O A068105 0,1
%A A068105 _Amarnath Murthy_, Feb 20 2002
%E A068105 Edited and extended by _Robert G. Wilson v_, Feb 21 2002
%E A068105 Corrected by _Don Reble_, Jan 17 2007