# Discrete Math- four digit odd integers with distinct digitst

a) Find the number of four-digit odd integers that have distinct digits. b) Find the number of four-digit even integers that have distinct digits.

I've been working on this problem and I can't figure it out. I don't know how to approach this problem. Any hints or maybe even a brief explanation of how to get the answer would be appreciated.

How can I get to the answer or what is the answer and how did you get to your conclusion?

Thanks a lot

• Is such an integer allowed to have $0$ as its first digit? – Newb Jan 30 '14 at 3:54
• no, the first digit must be different from 0. – kmitov Jan 30 '14 at 4:05

Hint: There are two types of $4$ digit odd integers with all digits different: (i) First digit is even ($2,4,6,8$) or (ii) first digit is odd. Count the Type (i) numbers, the Type (ii) numbers, and add.

Type (i): There are $4$ choices for the first digit. For each of these choices there are $5$ choices for the last digit. For each of the choices we have made so far, there are $8$ choices for the second digit, and for each such choice $7$ choices for the third, a total of $(4)(5)(8)(7)$.

Now it's your turn: make a similar calculation for Type (ii).

The analysis for the even numbers will be roughly similar. The two cases are (i) last digit is $0$ and (ii) last digit is not $0$.

Remark: The tricky thing is that the first digit cannot be $0$. A slightly nicer approach, I think, is to first allow $0$ as a first digit, and then take away the "numbers" with first digit $0$, which we should not have counted.

So for odd numbers, if we allow $0$ as a first digit, we can choose the last digit in $5$ ways, and then for the rest we have $(9)(8)(7)$ choices, for a total of $(5)(9)(8)(7)$.

Now if we have $0$ as the first digit, the rest can be filled in $(5)(8)(7)$ ways.

So our answer is $(5)(9)(8)(7)-(5)(8)(7)=2240$.

For the evens, the same analysis gives $(5)(9)(8)(7)-(4)(8)(7)$.

A good way to approach this kind of problem is to write down a step-by-step procedure for choosing the kind of arrangement you are asked for. For (a) this could be

(1) Choose the last digit of your number.

(2) Choose the first digit.

(3) Choose the second digit.

(4) Choose the third digit.

Then work out the number of ways of accomplishing each step. How many ways are there to choose the last digit? - hint: the number as a whole has to be odd. How many ways for step (2)? - hint: there is one digit it can't ever be, and also it has to be different from the last digit. And so on.

Once you have these four answers, how do you combine them to get the total answer? - hint: you have to do step (1) AND step (2) AND...

Good luck!

In the first case you have:

5 choises for the last position;

8 for the first

8 for the second

and 7 for the third.

then the number of numbers is 5.8.8.7=...

since the right most digit (units place) is restricted (odd or even) start there.

So we have Place: units, number of choices = 5

Place: tens, number of choices = 10-1 (you can't use the digit already used in the units place)

Place: hundreds, number of choices = 10-2 ( you have used two digits already) Place: thousands, number of choices=10-3. Assume that leading digit can be a zero

So the number of choices is = \$7\times 8\times9\times5 = 2526

If the leading digit can not be a zero then the number of choices in the thousands place is either 7 or 6 depending on if zero has already been used. The way to do this consider two cases: One where you have already used a zero, one where you have not used a zero in the units/tens/hundreds place and do the analysis