OFFSET
0,1
COMMENTS
Except for a(0), the same as A051238.
LINKS
T. D. Noe, Table of n, a(n) for n = 0..10000
Eric Weisstein's World of Mathematics, e Digits
Eric Weisstein's World of Mathematics, Constant Digit Scanning
EXAMPLE
The first 7 is in the 2nd position of the digits of e, so a(7) = 2.
PROG
(PARI) trajedigitsd(n, m) = { default(realprecision, 6000); p = exp(1)*10^5000; v = Vec(Str(p)); for(d=0, m, for(x=1, n, if(d<10, y = eval(v[x]), if(d<100, y = eval(v[x])*10 + eval(v[x+1]), if(d<1000, y = eval(v[x])*100 + eval(v[x+1])*10 + eval(v[x+2]), y = eval(v[x])*1000 + eval(v[x+1])*100 + eval(v[x+2])*10 + eval(v[x+3]) ); ); ); if(y == d, print1(x", "); break); ); ) }
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Cino Hilliard, Nov 19 2003
STATUS
approved