login
A244188
Numbers n such that the digit that repeats the most at the end of n^k for some k is not the last digit of n.
0
2, 12, 22, 33, 37, 42, 52, 62, 72, 73, 77, 92, 102, 112, 113, 117, 122, 142, 152, 153, 162, 172, 192, 197, 202, 212, 222, 233, 237, 242, 252, 262, 272, 273, 277, 292, 302, 312, 313, 317, 322, 342, 352, 353, 362, 372, 392, 397, 402, 412, 422, 433, 437, 442, 452, 462, 472
OFFSET
1,1
COMMENTS
a(n) ends in either a 2, 3, or 7.
If a(n) ends in a 2, the digit that repeats itself the most at the end of a(n)^k is 8.
If a(n) ends in a 3, the digit that repeats itself the most at the end of a(n)^k is 7.
If a(n) ends in a 7, the digit that repeats itself the most at the end of a(n)^k is 3.
The numbers that end in 2 are congruent to {2, 12, 22, 42} mod 50.
The numbers that end in 3 are congruent to {33, 73, 113, 153} mod 200.
The numbers that end in 7 are congruent to {37, 77, 117, 197} mod 200.
EXAMPLE
2^k ends in 2 of the same digit for k = 18 mod 20 (last digit is 4) and 19 mod 20 (last digit is 8). 2^k ends in 3 of the same digit for k = 39 mod 100 (last digit is 8). Since 8 is the only possibility, 8 must remain the only possibility for any larger run of identical digits. Since 8 is not the last digit of 2, then 2 is a member of this sequence.
33^k ends in 2 of the same digit for k = 1 mod 20 (last digit is 3) and 7 mod 20 (last digit is 7). 33^k ends in 3 of the same digit for k = 87 mod 100 (last digit is 7). Since 7 is the only possibility, 7 must remain the only possibility for any larger run of identical digits. Since 7 is not the last digit of 33, 33 is a member of this sequence.
PROG
(PARI) seq(n)=for(m=2, 6, cc=0; for(i=10^(m-1), 10^m, st1=(n^i)%10^m; b=""; for(j=1, m, b=concat(b, "1")); if(st1%eval(b)==0, for(d=i+1, 10^m, sb1=(n^d)%10^m; if(sb1%eval(b)==0, if(sb1%10==st1%10, return(st1%10)); if(sb1%10!=st1%10, cc++; break))))); if(cc==0, return(n%10)))
n=1; while(n<1000, if(seq(n)!=n%10, print1(n, ", ")); n++)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Derek Orr, Jun 22 2014
STATUS
approved