A mathematics competition had 9 easy and 6 difficult problems. Each of the participants in the competition solved 14 out of 15 problems. For each pair consisting of an easy and a difficult problem, the number of participants who solved both those problems was recorded. The sum of these recorded numbers was 459. How many participants were there?
Need help, don't really understand the question.
Please see the answer by barak manos for an explanation of what the problem asks. I’ll expand his explanation of the answer a little and show two ways to avoid trial and error, one specific to this problem and one general.
Recall that each participant missed only one problem. Let $x$ be the number of participants who missed a hard problem; each of them solved $9$ easy and $5$ hard problems and therefore solved $9\cdot5=45$ of the hard/easy pairs of problems. Let $y$ be the number of participants who missed an easy problem; each of these participants solved $8$ easy and $6$ hard problems and therefore solved $8\cdot6=48$ of the hard/easy pairs of problems. Altogether the $x+y$ participants solved $45x+48y$ hard/easy pairs, so $45x+48y=459$.
We can divide through by $3$ to reduce this to the equivalent equation $15x+16y=153$. This in turn can be rewritten as $15(x+y)+y=153$, which can be solved by inspection: clearly $153=15\cdot10+3$, so we set $y=3$ and $x+y=10$, finally getting $x=7$. As a check, $45\cdot7+48\cdot3=315+144=459$. Thus, $n=10$, $7$ participants solved all $9$ easy problems and $5$ of the hard problems, and $3$ participants solved all $6$ hard problems and $8$ of the $9$ easy problems.
It was a bit of luck that $153$ could so easily be decomposed in a useful way, so it’s worth pointing out that there are systematic techniques for solving such Diophantine equations.
First note that $15(-1)+16(1)=1$, so $15(-153)+16(153)=153$. That is, $x=-153,y=153$ is a solution to the equation $15x+16y=153$. Next, notice that if $15x_0+16y_0=153$, then
$$15(x_0+16)+16(y_0-15)=15x_0+15\cdot16+16y_0-16\cdot15=15x_0+16y_0=153\;.$$
Thus, if $x=x_0,y=y_0$ is a solution, so is $x=x_0+16,y=y_0-15$. In particular, for any integer $k$ we have a solution $x=-153+16k,y=153-15k$. The smallest integer $k$ such that $-153+16k\ge 0$, is $k=10$, giving the solution $x=7,y=3$ that we already found. Any smaller value of $k$ makes $x$ negative, and any larger value makes $y$ negative, so $x=7,y=3$ is the only solution of this kind. And in fact all solutions of $15x+16y=153$ are of this kind (and see also here).
Here I relied on inspection to get one solution ($x=-1,y=1$), but in general the extended Euclidean algorithm can be used to find one mechanically.