7
$\begingroup$

A five digit number has to be formed by using the digits $1,2,3,4$ and $5$ without repetition such that the even digits occupy odd places. Find the sum of all such possible numbers.

This question came in my test where you literally get $2$ minutes to solve one problem. I want to how to solve this problem more "mathematicaly" instead of listing all the $36$ cases.

$\endgroup$

closed as unclear what you're asking by Travis, Rohan, Claude Leibovici, GNUSupporter 8964民主女神 地下教會, user223391 Jan 18 '18 at 19:02

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • 2
    $\begingroup$ There are 3 odd places and 2 even numbers. What do you mean? $\endgroup$ – QuIcKmAtHs Jan 18 '18 at 12:37
  • 2
    $\begingroup$ @XcoderX That no even number occupies an even numbered spot. The problem didn't state in any way that the even number should occupy all the odd slots. $\endgroup$ – Arthur Jan 18 '18 at 12:38
  • $\begingroup$ but there are 2 even numbered spots $\endgroup$ – QuIcKmAtHs Jan 18 '18 at 12:40
  • 1
    $\begingroup$ @XcoderX And the two even numbers should avoid those two slots and instead use the three odd slots in any of the six possible ways. The two even slots and the remaining odd slot will have odd numbers in them. $\endgroup$ – Arthur Jan 18 '18 at 12:40
  • $\begingroup$ @Arthur Thanks, I understand now. $\endgroup$ – QuIcKmAtHs Jan 18 '18 at 12:43
15
$\begingroup$

Hint If you subtract a number satisfying the criterion from $66666$, you get a different number satisfying the criterion.

$\endgroup$
  • $\begingroup$ Sorry, I don't seem to understand this $\endgroup$ – QuIcKmAtHs Jan 18 '18 at 12:43
  • 3
    $\begingroup$ @XcoderX It's a hint. It's not meant to be immediately understood. It's meant to help you along your way. This takes the problem from 36 numbers to 18 pairs of numbers, where each pair hass a very nice property. If I say anything more this will cease to be a hint and become a solution. $\endgroup$ – Arthur Jan 18 '18 at 12:45
  • $\begingroup$ Oh yes I understand now. $\endgroup$ – QuIcKmAtHs Jan 18 '18 at 12:47
  • 2
    $\begingroup$ @Travis That was very brilliant. Thanks. $\endgroup$ – Voneone Jan 18 '18 at 12:59
  • 1
    $\begingroup$ @AnshulRaman You're welcome. Perhaps I can make the motivation for this solution a little more transparent. The time constraints of the problem more or less force you to group solutions in some way. The simplest nontrivial groupings are into groups of two, and it would be especially nice to pair in such a way that each pair has the same sum (a la Gauss' solution to evaluating the sum $1 + 2 + \cdots + 99 + 100$). $\endgroup$ – Travis Jan 18 '18 at 14:41
2
$\begingroup$

Choose a position for the $2$. How many of these numbers have the $2$ in that position? There are two options for the $4$ and $3!$ options for the remaining $3$ numbers, that gives you $12$ numbers. Hence the $2$ brings $12\times 20202$ to the sum. Similarly the $4$ brings $12\times 40404$.

Now if you fix an odd number at an even place there are $6$ ways to put the even numbers and then $2$ ways to put the other two odd ones. So $1$ brings $12\times 1010$, $3$ brings $12\times 3030$ and $5$ brings $12\times 5050$.

Finally if you fix an odd number at an odd place there are $2$ options for the other odd ones and $2$ options for the even ones.

Altogether $$S=12\times 69696+4\times 90909$$

$\endgroup$

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