4
$\begingroup$

...and where no digit is to be repeated in any 4-digit number.

Yes, I am aware of similar questions on this site, but none of the answers gave me insight as to how this works.

I would like an answer in ridiculously simple terms, like explaining it to a 5 year old.

One answer:

Total numbers formed using those 5 digits is 5P4. i.e. 120 numbers.

Since all digits will equally occupy the unit's place, therefore 1 will occur 24 times in unit's place. Similarly 2 will occur 24 times in unit's place. So on and so forth. Therefore sum of all digits in unit's place will be equal to 24 x (1+2+3+4+5)=24 x 15.

Similarly sum of all digits in ten's place will be equal to 24 x 150.

Therefore total sum of all numbers =24 x (15+150+1500+15000)=399960 .

Why is there the sum (1 + 2 + 3 + 4 + 5)? Am I misreading the question? Does "no digit is to be repeated in any 4-digit number" mean that there shouldn't be a number like 4432, or does it mean that a number should not be repeated in the same "unit slot"?

$\endgroup$
  • $\begingroup$ When it says no digit is to be repeated in any 4 digit number, it means 4432 would not be valid, since there are two 4s in the number (all digits in a number should be unique). $\endgroup$ – user2825632 Sep 8 '16 at 17:39
  • $\begingroup$ Yeah, I thought so. But I couldn't figure out for the life of me how one got (1 + 2 + 3 + 4 + 5). It seemed to me that you could only do that if you would know that those are the only numbers that would fit into a "unit slot". With unit slot I mean the unit place, the tens place, the hundreds place, etc. $\endgroup$ – Garth Marenghi Sep 8 '16 at 17:41
  • 1
    $\begingroup$ The point the answer you share is trying to make, is that if we were to write out the list of all of the answers in a grid, instead of adding each row at a time, we may instead add each column at a time. In the same way that it is useful to think of $247 + 132$ instead as $\begin{matrix}&2&4&7\\+&1&3&2\end{matrix}$, adding column by column. In this specific problem, there will be 120 rows in our addition and five columns. We notice that in each column, the numbers 1,2,3,4,5 each occur equally often, i.e. there are 24 1's in the first column as well as 24 2's, 24 3's, etc... $\endgroup$ – JMoravitz Sep 8 '16 at 17:44
  • $\begingroup$ The sum of the $120$ digits in the units column is $24\times 1 + 24\times 3 + 24\times 3 + 24\times 4 + 24\times 5$. Then factor out the $24$ $\endgroup$ – Henry Sep 8 '16 at 17:44
  • $\begingroup$ @JMoravitz This! This is the one that made the quarter drop (a saying in my language, Dutch). I understand! I finally understand! You brought a tear to my eye, my friend! (Also thanks to everyone who commented ;-)) $\endgroup$ – Garth Marenghi Sep 8 '16 at 17:50
2
$\begingroup$

Your answer is trying to say that when you write out all 120 numbers, it will look something like this:

1234

1235

...

2134

2135

...

5123

5124

There will be 24 ones in the thousands place, 24 twos in the thousands place, etc. This is because once we set a certain number in the thousands place (e.g. one), then we have 24 distinct four digit numbers.

So we calculate the sum of the 120 valid 4 digit numbers by first looking at the sum of the digits in the thousands place. This sum is $$1000 * 24 * 1 + 1000 * 24 * 2 + 1000 * 24 * 3 + 1000 * 24 * 4 + 1000 * 24 * 5$$

The 1000 comes from looking at the sum of the digits in the thousands' place. The solution you provided factored this result as $1000 * 24 * (1+2+3+4+5)$.

Now that we've calculated the sum of the digits in the thousands' place, we can do the same for the hundreds' place, tens' place, and ones' place similarly:

Hundreds' Place: $100 * 24 * (1+2+3+4+5)$

Tens' Place: $10 * 24 * (1+2+3+4+5)$

Ones' Place: $1 * 24 * (1+2+3+4+5)$

Adding these values together, we get the answer, which is 399960.

$\endgroup$
  • $\begingroup$ Yeah, this is exactly it. As you could probably see, someone provided in the comment section on my question the key idea that finally made it click. Your answer clarified it even more, so, thank you! $\endgroup$ – Garth Marenghi Sep 8 '16 at 17:57
2
$\begingroup$

It's just a shorthand for adding up the $120$ possible values of the ones place.

The digit $1$ occurs $24$ times, as does $2, 3, 4,$ and $5$,

If your digits were $(2,4,5,7,9)$ then the sum would be $24 \times (2+4+5+7+9)$.

$\endgroup$
  • $\begingroup$ Thank you for providing an answer. The key had come already in a comment I got, but this solidifies it further. Thanks! $\endgroup$ – Garth Marenghi Sep 8 '16 at 17:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.