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 A036013 #26 Jan 20 2024 09:16:55 %S A036013 2,2,2,3,2,4,2,3,6,4,5,5,5,10,4,3,5,8,22,13,14,2,5,5,2,20,9,9,24,5,26, %T A036013 15,14,25,25,4,9,30,9,21,12,11,10,2,40,19,8,13,11,50,3,25,25,8,5,25, %U A036013 46,19,47,54,9,13,14,43,4,24,28,16,33,25,152,2,11,22,6,78,87,7,10,21 %N A036013 a(n) = smallest number > 1 such that a(1)a(2)...a(n) - 1 is prime (or 1). %H A036013 Michael S. Branicky, <a href="/A036013/b036013.txt">Table of n, a(n) for n = 1..1600</a> (terms 1..300 from T. D. Noe) %t A036013 sng1[{t_,a_}]:=Module[{k=2},While[CompositeQ[t k-1],k++];{t*k,k}]; NestList[sng1,{2,2},80][[;;,2]] (* _Harvey P. Dale_, May 20 2023 *) %o A036013 (Python) %o A036013 from sympy import isprime %o A036013 from itertools import count %o A036013 a,p = [2],2 %o A036013 for _ in range(100): %o A036013 q = next(filter(lambda x:isprime(x*p-1), count(2))) %o A036013 p = p*q %o A036013 a.append(q) %o A036013 print(a) # _Nicholas Stefan Georgescu_, Mar 06 2023 %Y A036013 Cf. A036012, A058000 (corresponding primes). %K A036013 nonn,nice,easy %O A036013 1,1 %A A036013 _Russell Easterly_ %E A036013 More terms from _Erich Friedman_. More terms from _Jud McCranie_, Jan 26 2000.