Quote:

Originally Posted by **mathsmad**

A palindromic number is one that reads the same from left to right or from right to left. For example, 64746 is a palindromic number.

a/ How many odd six-digit palindromic numbers are there?

b/ How many odd seven digit palindromic numbers are there in which every digit appears at most twice?

Consider an odd number <=999. Each of these gives a unique six-digit

palindromic number as follows:

first add as many zeros to the front of the number as needed so that we

have exactly three digits. Reverse the digits and append reversed copy to

the front of the three digits.

It is self evident that any six-digit palindromic number can be generated in

this manner.

Therefore there are exactly as many six-digit palindromic numbers as there

are odd numbers <=999. There are exactly 500 odd numbers <=999, so

there are exactly 500 six-digit palindromic numbers.

For seven-digit odd palindromic numbers the three most and the three least

significant digits are the digits of a six-digit palindromic number. Thus for

each possible middle digit there are 500 seven-digit palindromic numbers. The

possible middle digits are 0, 1, 2, .., 9. Hence there are 5000 seven-digit

odd palindromic numbers.

RonL