Let us call X the number of pounds of $6 candies and Y the number of pounds of $9 candies. We know that: X+Y=15 (we are picking a total of 15 pounds) (6X+9Y)/15=7 (the average of each pound out of those 15 is "valued" $7)
So you can deduce that Y=15-X Then replace Y in the other equation by 15-X which is: (6X+9*(15-X))/15=7 (6X+135-9X)/15=7 (135-3X)/15=7 135-3X=7*15 135-3X=105 -3X=-30 X=10
So you can deduce that Y=15-10=5
As a matter of fact you can verify that 10 pounds of the first candies are valued $60 and 5 pounds of the seconds are valued $45 which is a total of 105. 105/15=7 which means that the overall 15 pounds do have an average per-pound-value of $7.