Question

# $A$ and $B$ each have a certain number of mangoes. $A$ says to $B$ , “If you give $30$ of your mangoes, I will have twice as many as left with you.” $B$replies, “if you give me $10$, I will have thrice as many as left with you.” How many mangoes does each have?

Hint: Always start by assigning x entities to one and according to that assign the next variable if they are related and if not assign another variable.
Let us assume the number of mangoes $A$ has is $x$,
And the number of mangoes $B$ has is $y$.
Therefore, if we look at the condition given in the question, for $A$,
$30 + x = 2\left( {y - 30} \right)$ …..(1)
And for B,
$10 + y = 3\left( {x - 10} \right)$ …..(2)
Note: Make sure the equations formed are correct and satisfy the question’s conditions.
On simplification of the above two equations, we get
$x - 2y + 90 = 0$ …..(3)
And the second equation becomes,
$- 6x + 2y + 80 = 0$…..(4)
Let us add (3) and (4),
$- 5x + 170 = 0$
From here, we get the value of $x = 34$
Therefore, $A$ has $34$ mangoes.
Now, let us put the value of $x$ in (1),
$34 - 2y + 90 = 0$
$2y = 124$
$y = 62$
Therefore, $B$ has $62$ mangoes.