The conversation between human and AI assistant.
What is the sum of all 4 digit numbers that can be formed by the digits 0, 1, 2, 3, 4? No repetitions allowed.
How did you come up with that answer?
I calculated the sum by taking the average of all the possible combinations of those 5 digits and multiplying by the number of combinations. The average is 2222.5, and there are 5!/(5-4)! = 120 combinations. So the sum is 2222.5 * 120 = 266700, but we need to subtract 5000 because the digit 0 can't be used as the first digit, so the final answer is 666600.