login
First repdigit number with n digits occurring in the decimal expansion of e, starting after the decimal point.
6

%I #38 Aug 13 2022 20:26:49

%S 7,66,999,8888,66666,0,5555555,99999999,111111111,1111111111

%N First repdigit number with n digits occurring in the decimal expansion of e, starting after the decimal point.

%C A244601 allows consecutive 0's and says "Resulting repdigits are A244602", so 000000 = 0 is apparently allowed here as a repdigit with 6 digits. Otherwise a(6) would be 555555 at position 210482 (which extends to a seventh 5). - _Jens Kruse Andersen_, Jul 20 2014

%H <a href="http://www.subidiom.com/e/">e digit search engine</a>

%e Decimal expansion of e:

%e 2.|7|18281828459045235360287471352|66|24977572470936|999|59574966967627724..

%t e = Rest[First[RealDigits[E, 10, 2000000]]];

%t A244602 = ConstantArray[0, 8];

%t For[i = 1, i <= Length[e], i++,

%t t = e[[i]]; c = 1;

%t While[e[[i + c]] == t, c++];

%t If[A244602[[c]] == 0,

%t A244602[[c]] = FromDigits[ConstantArray[t, c]]; i = i + c - 1;

%t Continue[]]

%t ]; A244602 (* _Robert Price_, Sep 07 2019 *)

%t With[{edg=Rest[RealDigits[E,10,10^6][[1]]]},Table[FromDigits[SequenceCases[ edg, PadRight[ {},n,x_],1][[1]]],{n,7}]] (* The program generates the first seven terms of the sequence. *) (* _Harvey P. Dale_, Aug 13 2022 *)

%Y Cf. A010785, A244601.

%K nonn,base,more

%O 1,1

%A _Felix Fröhlich_, Jul 01 2014

%E a(5)-a(8) from _Jens Kruse Andersen_, Jul 20 2014

%E a(9)-a(10) from _Felix Fröhlich_, Aug 26 2014

%E a(1) prepended by _Alois P. Heinz_, Aug 26 2014