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 A071126 #30 Jul 24 2025 20:32:46 %S A071126 0,3,0,6,2,6,16,18,22,28,15,3,5,21,46,13,58,60,33,35,8,13,41,44,96,4, %T A071126 34,53,108,112,42,130,8,46,148,75,78,81,166,43,178,180,95,192,98,99, %U A071126 30,222,113,228,232,7,30,50,256,262,268,5,69,28,141,146,153,155,312,79,110 %N A071126 Length of least repunit which is a multiple of the n-th prime, or 0 if no such multiple exists. %C A071126 If prime(n) = p then a(n) is a divisor of p-1. - _Amarnath Murthy_, Nov 11 2002 %H A071126 Michael De Vlieger, <a href="/A071126/b071126.txt">Table of n, a(n) for n = 1..1000</a> %H A071126 P. De Geest, <a href="https://www.worldofnumbers.com/repunits.htm">Repunits and Their Factors</a> %H A071126 Amarnath Murthy, <a href="http://rxiv.org/abs/1403.0524">On the divisors of Smarandache Unary Sequence</a>, Smarandache Notions Journal, Vol. 11, 2000. %H A071126 A. A. A. Steward, <a href="/A071126/a071126_1.txt">Factorization of Repunits[up to R(196)]</a>. Cached copy, Sep 25 2000. %H A071126 Michael De Vlieger, <a href="/A071126/a071126.txt">Records and positions in first 1000 terms of A071126</a> %e A071126 The 13th prime, 41, divides the repunit 11111, the smallest among all R(5k) which are multiples of 41. %t A071126 Table[Function[p, If[Divisible[10, p], 0, k = {1}; While[! Divisible[ FromDigits@ k, p], AppendTo[k, 1]]; Length@ k]]@ Prime@ n, {n, 67}] (* _Michael De Vlieger_, May 20 2017 *) %o A071126 (Python) %o A071126 from sympy import prime %o A071126 from itertools import count %o A071126 def a(n): %o A071126 if n == 1 or n == 3: return 0 %o A071126 pn = prime(n) %o A071126 return next(k for k in count(1) if 10**k//9%pn == 0) %o A071126 print([a(n) for n in range(1, 68)]) # _Michael S. Branicky_, Jul 24 2025 %Y A071126 Number of 1's in A077573(n). %Y A071126 Cf. A000042. Apart from a(2), identical to A002371. %K A071126 nonn %O A071126 1,2 %A A071126 _Lekraj Beedassy_, May 28 2002