login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A244613 Least number k > 0 such that 2^k ends in exactly n consecutive increasing digits. 1
1, 8, 28, 328, 1328, 11328 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

For n = {1, 2, 3, 4, 5, 6}, the n consecutive increasing digits, given by 2^a(n)%10^n, are {2, 56, 456, 3456, 23456, 123456}, respectively.

There are 12500 possible 6-digit endings for 2^k. There are no k-values such that 2^k ends in '234567', '345678', or '456789'. The k-values for which 2^k ends in '123456' are given by 11328 mod 12500. For k = 11328 + 12500*x, the digit immediately before the run of '123456' is {1, 3, 5, 7, 9, 1, 3, 5, 7, 9, 1, 3, ...} for x = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, ...}, respectively. Thus, we see the digit before will never be 0. So, this sequence is full.

LINKS

Table of n, a(n) for n=1..6.

EXAMPLE

2^8 = 256 ends in '56'. Thus a(2) = 8.

2^28 ends in '456'. Thus a(3) = 28.

PROG

(PARI) a(n)=for(k=1, 10^6, st=2^k; c=0; if(#Str(st)>n, for(i=1, n, if(((st-(st%10^(i-1)))/10^(i-1))%10==((st-(st%10^i))/10^i)%10+1, c++)); if(c==n, return(k))))

n=0; while(n<10, print1(a(n), ", "); n++)

(Python)

def a(n):

..for k in range(1, 10**5):

....st = str(2**k)

....if len(st) > n:

......count = 0

......for i in range(len(st)):

........if int(st[len(st)-1-i]) == int(st[len(st)-2-i])+1:

..........count += 1

........else:

..........break

......if count == n:

........return k

n = 0

while n < 10:

..print(a(n), end=', ')

..n += 1

CROSSREFS

Sequence in context: A316512 A200034 A230702 * A228281 A146977 A068623

Adjacent sequences: A244610 A244611 A244612 * A244614 A244615 A244616

KEYWORD

nonn,base,fini,full

AUTHOR

Derek Orr, Jul 02 2014

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 27 12:09 EDT 2023. Contains 361570 sequences. (Running on oeis4.)