x amount earns 4% interest
y amount earns 8% interest
The total investment is $1000, so the first equation is
x + y = 1000
x amount at 4% earns 0.04x interest
y amount at 8% earns 0.08y interest
The total interest earned is $50, so our second equation is
0.04x + 0.08y = 50
We have a system of two equations in two unknowns.
x + y = 1000
0.04x + 0.08y = 50
Multiply the first equation by -0.04 and add to the second equation.
-0.04x - 0.04y = -40
+ 0.04x + 0.08y = 50
-----------------------------------
0.04y = 10
Divide both sides by 0.04:
y = 250
Substitute y = 250 in the first equation to find x.
x + y = 1000
x + 250 = 1000
x = 750
Answer: x = 750, y = 250