# Apple puzzle math

For convenience, he put some apples in 3 types of boxes, boxes of 1kg, 3kg and 5kg. He has a total of 10 cases of various kinds.

Can he put 25kg apple to fit into 10 boxes?

I'm thinking about creating $x,y,z \in \mathbb{N}$ and makes 3 equations to solve $x,y,z$ But I'm lack 1 equation to solve :(

-
Since you only need to know if there is a solution, you don't need three equations to solve this problem. The trick is that you are looking for whether there are natural number solutions. –  Thomas Andrews Sep 5 '12 at 15:39
Do you have to end up with (i) ten full boxes/cases; or (ii) some full boxes and some empty boxes; or (iii) can some boxes end up part full? –  Mark Bennet Sep 5 '12 at 15:42

If $x$ is the number of 1kg boxes, $y$ the number of 3kg boxes and $z$ the number of 5kg boxes, you want to solve

$x+y+z = 10$ so that 10 boxes are used

$x+3y+5z = 25$ so that 25kg of apples are used.

Additionally, you have the constraints that $x,y,z$ are non-negative integers. There is no third equation involved, there may be several solutions - or already none because of the integer constraints.

In fact, subtracting the first from the second equation produces $2y+4z = 15$. The left hand side is even, the right hand side is odd. This can't be, hence there is no solution. The answer to the question is "no".

-
so helpful :x thanks –  Vchau_VN Sep 5 '12 at 15:55

You can set up equations. If we use $x$, $y$, $z$ boxes of size $1$, $3$, $5$ respectively, then $x+3y+5z=25$ and $x+y+z=10$. Subtract. You get $2y+4z=15$. This is impossible in integers, since $2y+4z$ is always even, and $15$ is odd.

So we cannot solve the problem using exactly $10$ boxes.

Remark: If we use an even number of boxes, the number of apples will always be even. For if we use an even number of boxes, then either (i) we use an even number of each kind or (ii) we use odd numbers of two kinds, and an even number of another. In case (i) it is clear that the number of apples will be even. The same is true in case (ii).

-
thankss so much :) –  Vchau_VN Sep 5 '12 at 15:54

If $x,y,z$ are integers such that $x+y+z=10$, then there are two possibilities:

$\hskip1cm$ (i) All of $x,y,z$ are even numbers.

$\hskip1cm$ (ii) One of $x,y,z$ is even and the two other numbers are odd.

In both cases, $x+3y+5z$ will be an even number, so it cannot be equal to $25$.

-
\begin{align*} x+3y+5z &= 25 \\ x+y+z &= 10 \end{align*}
And indeed, you only have two equations. However, you have the following constraints: $x,y,z$ are integers.
Subtract the second from the first and you can eliminate $x$ -- can integers $y$ and $z$ solve the resulting equation?