How many six digit numbers can be formed from 0,1,2,....8,9 such that,every number contains exactly 3 distinct digits
-
UP 0 DOWN 0 1 2
2 Answers
Suddenly i feel i got a better easier soln.. this was a bit clumsy in the Case 2.. and krishna could probably not understand the logic...
find all numbers of 6 or less digit which are formed by 3 digits..
remove those cases where the first digit is 0
No of ways to select them = 10C3
arrange them in 6 digits so that each comes atleast once =
sub-cases : 1+1+4 = 6!/4!
1+2+3 = 6!/2!3!
2+2+2 = 6!/2!2!2!
Total = 10C3 * ( 3.6!/4! + 3!.6!/2!3! + 6!/2!2!2! )
120*540 = 64800
Now remove those cases when the first digit was 0
***edit***
The numbers with first digit 0 will be equal to that with first digit 1 or 2 or .... 9
hence 1/10th of the above numbers will be those starting with 0.
so answer will be 64800-64800/10
= 58320
which btw confirms to our first answer..
so the answer u have is wrong.!!!!!!!!!
***end edit***
Case 1:
chose 3 distinct digits leaving 0 : 9C3
sub-cases : 1+1+4 = 6!/4!
1+2+3 = 6!/2!3!
2+2+2 = 6!/2!2!2!
***edit***
Total solution for this case = 540*84 = 45360
***end edit***
Case 2:
chose 3 distinct digits including 0
assume p,q,0
first digit is in 2 ways (p or q) assume p
5 digits remain.. 0 and q have to have atleast 1 spot
take the cases now..
there are too many calculations.. so do the dirty work..
***Edit***
Let the first digit be p.
so remaining 5 digits should have atleast 1 q and 1 0
cases:
p q 0 : No of cases...
0 1 4 : 5
0 2 3 : 10
0 3 2 : 10
0 4 1 : 5
1 1 3 : 20
1 2 2 : 30
1 3 1 : 20
2 1 2 : 30
2 2 1 : 30
3 1 1 : 20
The total for this comes to be 180
there will be same 180 cases when q is the first digit!!
p and q can be chosen in 9C2 ways. = 36
Total ways in this case = 36*180*2 = 6480*2
***End Edit***
Answer = 6480*2+ 45360 = 58320
Now look at the anser you gave me..
it is 6480+ 45360 = 52840
So it is wrong.. I will give another prooof.. 1 liner for the whole question.. just struck me when i was solving this..