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!)
A222810 Number of n-digit numbers N with distinct digits such that the reversal of N divides N. 7

%I #27 Dec 15 2014 02:39:39

%S 9,9,3,5,3,2,0,0,0

%N Number of n-digit numbers N with distinct digits such that the reversal of N divides N.

%C Suggested by A214927.

%C a(n)=0 for all n > 6.

%e Solutions with 1 through 6 digits:

%e [1, 2, 3, 4, 5, 6, 7, 8, 9],

%e [10, 20, 30, 40, 50, 60, 70, 80, 90],

%e [510, 540, 810],

%e [5610, 5940, 8712, 8910, 9801],

%e [65340, 87120, 87912],

%e [659340, 879120],

%o (Python)

%o import collections

%o col = []

%o count = 0

%o for n in range(0,9):

%o ....a = 10**n

%o ....stop = 10**(n+1)

%o ....while a < stop:

%o ........b = str(a)

%o ........c = list(b)

%o ........d = c[::-1]

%o ........e = int("".join(c))

%o ........f = int("".join(d))

%o ........counter = collections.Counter(c)

%o ........if e % f == 0 and counter.most_common(1)[0][1] == 1:

%o ............count += 1

%o ............col.append(a)

%o ........a += 1

%o ....print(n+1," digits: ",count," elements: ",col)

%o ....count = 0

%o ....col = []

%o # _David Consiglio, Jr._, Dec 04 2014

%Y Cf. A214927, A222809, A222811, A222812.

%Y For the actual numbers see A223080.

%K nonn,base

%O 1,1

%A _N. J. A. Sloane_, Mar 10 2013

%E a(8)-a(9) from _David Consiglio, Jr._, Dec 04 2014

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 August 12 23:53 EDT 2024. Contains 375113 sequences. (Running on oeis4.)