Sum of all numbers formed by the given digits
I figured the answer out.
If you fix 1 in the thousands place, all other numbers can be arranged in 3! Ways.
Therefore 1 occurs in thousands place 3! Times. Same for all the numbers. Therefore for thousands place, total sum= 1000(sum) 3!.
But same thing occurs for all other positions. Therefore sum= 1111...×(sum) ×(n-1)!