In: Statistics and Probability
How many different positive integers less than 1000 have distinct digits and are even?
My attempt:
since 1 digit numbers have the repeating 0 digit i started with 2 digit numbers.
xxx=
First digit: can only be 0
Second digit: can be any of 9 digits
Third digit: can't be 0 or the digit used in the tens column so one of 4 numbers.
1*9*4= 36 ways
so 1 * 9 * 4= 36 ways
Now for the 3 digit numbers.
xxx=
First digit: can be any other number than 0 so 9 options
Second digit: can't be the number from the hundreds column but it can be 0 so again 9 options
Third digit: has to be even so 5 options but if the tens column number is a 0 there is only 4 options.
My question has to do with the last digit in the 3 digit numbers, how do you handle a case like that where the number of options changes depending on the pervious input? What is the logical reasoning behind how to find the answer? This is my first Stats class so solving these types of problems is foreign to me. Thank you.
Solution:
We will have to take following three cases
1-digit numbers:
There are 4 even 1-digit number which are less than 1000 (2, 4, 6, 8)
So number of 2-digit even number with distinct digits = 4
2-digit numbers:
There are 45 2-digit even number which are less than 1000 (10, 12, 14, ...., 96 ,98)
However, since we have to consider number with distinct digit so 22, 44, 66, 88 cannot be included. so we need to subtract 4 from total two-digit even numbers
So number of 2-digit even number with distinct digits = 45 - 4 = 41
3-digit numbers:
The first digit of an 3-digit number can be odd or even but it has to be non zero. The second digit of a 3-digit number can be odd or even, however, it can be zero as well. The third digit of an 3-digit number must be even as we have to count even numbers only. However, it should be noted that all digits should be distinct.There are 4 cases that we have to consider for 3-digit number.
Case 1. odd(hundreds), odd(tens), even(ones): 5*4*5 = 100 (There are 5 odd and 5 even number. There are 5 ways in which odd digit in hundreds column can be selected, corresponding to which there are 4 ways in which odd digit tens column can be selected as we cannot chose same odd digit chosen for hundreds column. There are are 5 ways in which even number can be selected for evens column as even number has not been used earlier)
Case 2. odd(hundreds), even(tens), even(ones): 5*5 *4 = 100 (There are 5 odd and 5 even number. There are 5 ways in which odd digit in hundreds column can be selected. There are are 5 ways in which even number can be selected for tens column as even number, corresponding to which there are 4 ways in which even digit for ones column can be selected as we cannot chose even number that was chosen for tens column)
Case 3. even, odd, even: 4*5*4 = 80
Case 4. even, even, even: 4*4*3 = 48.
So number of 3-digit even number with distinct digits = 100 + 100 + 80 + 48 = 328
Total no. of distinct and even positive integers less than 1000 = No. of 1-digit numbers + No. of 2-digit numbers + No. of 3-digit numbers
Total no. of distinct and even positive integers less than 1000 = 4 + 41 + 328 = 373
Answer: 373 different positive integers less than 1000 have distinct digits and are even