Math Problem F.1 Buy apple and orange

I planned to buy 20 apples and oranges in total. one apple costs 70 yen and one orange costs 40 yen. 

However, because I bought the number of apples and oranges adversely, 120 yen remained. 

Find the amount of money planned?











Answer
1160 yen

Solution
As for buying the number of apples and oranges adversely and the remainder is 120 yen, it is understood that the number of apples was more than that of orange in the plan. 

Whenever one apple is replaced with one orange, difference of the total price is 70 yen - 40 yen = 30 yen. 

Differing for 120 yen means that 120 yen / 30 yen = 4 apples was more than the number of oranges. 

The sum is 20 and the difference is 4. 

It is found that the number of apples is (20 + 4) / 2 = 12 and the number of oranges is 20 - 12 = 8. 

Therefore, the amount of money of the plan is 70 yen × 12 pieces + 40 yen × 8 pieces = 1160 yen.