A good way (not necessarily the best way) of doing such a problem as advised by my high school teacher is to first determine the number of combinations, then follow by permuting their arrangements. For your question, there are two cases, one of the four digits repeating three times, and two of the digits repeating twice each.
For the first case, the number of ways to choose a digit repeating three times is 4C1.
The possible arrangements for this case is 6!/ 3!
Then the number of six-digit numerals associated to this case will be the product of these two numbers.
For the second case, repeating the previous argument, we have the number of combinations as 4C2.
and the number of arrangements as 6!/2! * 2!
Again, the product of these two numbers will be the number of six-digit numerals associated to this case.
Adding the two cases together, you will obtain the answer.
Regards
Arun (askIITians forum expert)