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.

A045875 a(n) is the smallest m for which the decimal representation of 2^m contains n consecutive identical digits.

This page as a plain text file.
%I A045875 #47 Aug 07 2025 20:22:30
%S A045875 0,16,24,41,220,971,972,8554,42485,42486,271979,1039315,1727602,
%T A045875 6855865,63416789,106892452,356677212
%N A045875 a(n) is the smallest m for which the decimal representation of 2^m contains n consecutive identical digits.
%C A045875 a(9) > 20000. - _David Wasserman_, Feb 16 2002
%C A045875 a(11) > 250000. - _Robert G. Wilson v_, Oct 21 2010
%C A045875 a(15) > 10297974. - _T. D. Noe_, Sep 08 2012
%C A045875 a(17) > 107000000. - _Paul Geneau de Lamarlière_, Feb 04 2024
%t A045875 a[n_] := Block[{k = 0}, While[ !MemberQ[ Length /@ Split@ IntegerDigits[2^k], n], k++ ]; k]; Table[a[n], {n, 6}] (* _Robert G. Wilson v_, Oct 21 2010 *)
%o A045875 (Python)
%o A045875 def A045875(n):
%o A045875     l, x = [str(d)*n for d in range(10)], 1
%o A045875     for m in range(10**9):
%o A045875         s = str(x)
%o A045875         for k in l:
%o A045875             if k in s:
%o A045875                 return m
%o A045875         x *= 2
%o A045875     return 'search limit reached'
%o A045875 # _Chai Wah Wu_, Dec 17 2014
%Y A045875 Cf. A215732 (the digits).
%K A045875 base,nonn,hard,more
%O A045875 1,2
%A A045875 _Erich Friedman_
%E A045875 More terms from _David Wasserman_, Feb 16 2002
%E A045875 a(9) and a(10) from _Robert G. Wilson v_, Oct 21 2010
%E A045875 a(11)-a(13) added by _T. D. Noe_, Sep 04 2012
%E A045875 a(14) added by _T. D. Noe_, Sep 06 2012
%E A045875 Definition clarified by _Daran Gill_, Mar 24 2013
%E A045875 a(15) from _Bert Dobbelaere_, Feb 25 2019
%E A045875 a(16) from _Paul Geneau de Lamarlière_, Feb 04 2024
%E A045875 a(17) from _Paul Geneau de Lamarlière_, Sep 24 2024