I assume the question asks for the numbers using "all the digits", so, the numbers are just 6 digit ones. If not, we will need further summations, both logic wont change.
First of all, we can form 6!/(3!2!) = 60 different numbers. We can think digits seperately.
Think of 2: There are six different combinations for 2, each is equally likely, so, each one must be counted 10 times, while other digits change.
For 2 is the leftmost digit, we have 200000, for one lower digit, we have 20000, ... and 2. We have 10 of each of them.
So, we have (200000 + 20000 + 2000 + 200 + 20 + 2 ) x 10 = 222222 x 10 as sum.
Think of 3: There are C(6,2) = 15 different places for 3. Each one is equally likely, so, each one must be counted 60/15 = 4 times. Different from 2, we now hold one of the three's and let other one travel through digits. So, we hold one of them, while the other travels each 5 remaining. So, we must multiply the usual result by 5.
i.e. 330000, 303000, 300300, 300030, 300003 which yields 300000 x 5 + 33333
Then similarly we have 30000 x 4 + 3333, 3000 x 3 + 333, 300 x 2 + 33, 30 x 1 + 3
which yields 333333 x 5 yields 333333 x 20
Then multiply this with 4,
Think of 4: There are C(6,3) = 20 different places of 4's. Each one is equally likely, so each one must be counted 60/20 = 3 times. And we hold 1 of 4's while the other two travels, we have C(5,2) = 10 different travel combinations, while one four is constantlt sitting at some digit:
444000, 440400, 440040, 440004
404400, 404040, 404004,
400440, 400404,
400044
So, we have 444444 x 10 x 3.
Total sum is 111111 x 10 x (1x2 + 2x3 + 3x4) = 200 x 111111 = 22222200