login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A171252
Least power of 2 to have at least n consecutive digits 'n' in its decimal expansion
7
0, 0, 43, 83, 192, 973, 2269, 972, 25263, 42485
OFFSET
0,3
COMMENTS
As it stands, the definition makes only sense for (decimal digits) n=0,...,9. Replacing "decimal" by, e.g., base-(prime(n)), the sequence could be defined for all n. (However, e.g., base-(n+1) would not work, since in base 4 no power of 2 has a digit "3".)
PROG
(PARI) A171252(n)={my(p=10^n, t); n*=p\9; for(k=0, 1e9, t=2^k; until( n>t\=10, t%p==n & return(k)))}
for(d=0, 9, print(d" "A171252(d)))
CROSSREFS
Sequence in context: A289730 A045238 A139982 * A119487 A180549 A247436
KEYWORD
base,fini,full,nonn
AUTHOR
M. F. Hasler, Dec 06 2009
STATUS
approved