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 A256480 #16 May 22 2025 10:21:42 %S A256480 0,11,0,13,0,0,0,17,0,19,0,211,0,113,0,0,0,317,0,419,0,421,0,223,0,0, %T A256480 0,127,0,229,0,131,0,233,0,0,0,137,0,139,0,241,0,443,0,0,0,347,0,149, %U A256480 0,151,0,353,0,0,0,157,0,359,0,461,0,163,0,0,0,167,0,269 %N A256480 Smallest prime obtained by appending n to a nonzero number with identical digits or 0 if no such prime exists. %C A256480 a(n) = 0 if n is even or a multiple of 5. Conjecture: all other terms are nonzero. Conjecture verified for n <= 10^7. %C A256480 "Appending" means "on the right". %H A256480 Chai Wah Wu, <a href="/A256480/b256480.txt">Table of n, a(n) for n = 0..10000</a> %H A256480 Chai Wah Wu, <a href="http://arxiv.org/abs/1503.08883">On a conjecture regarding primality of numbers constructed from prepending and appending identical digits</a>, arXiv:1503.08883 [math.NT], 2015. %o A256480 (Python) %o A256480 from gmpy2 import digits, mpz, is_prime %o A256480 def A256480(n,limit=2000): %o A256480 sn = str(n) %o A256480 if not (n % 2 and n % 5): %o A256480 return 0 %o A256480 for i in range(1,limit+1): %o A256480 for j in range(1,10): %o A256480 si = digits(j,10)*i %o A256480 p = mpz(si+sn) %o A256480 if is_prime(p): %o A256480 return int(p) %o A256480 else: %o A256480 return 'search limit reached.' %Y A256480 Cf. A090287, A256481. %K A256480 nonn,base %O A256480 0,2 %A A256480 _Chai Wah Wu_, Mar 31 2015