Ok, so
We could solve this problem using a system of linear equations as follows:
x = amount invested at 6%
y = amount invested at 9%
We are given two numbers in the problem:
$5000 = total money invested in both accounts
$393 = total interest earned in both accounts
Then we could write:
[tex]\begin{cases}x+y=5000 \\ 0.06x+0.09y=393\end{cases}[/tex]This system can be solved using sustitution:
[tex]y=5000-x[/tex]Replacing:
[tex]\begin{gathered} 0.06x+0.09(5000-x)=393 \\ 0.06x+450-0.09x=393 \\ -0.03x=-57 \\ x=1900 \end{gathered}[/tex]And y = 5000 - x, which is 5000 - 1900, and that is 3100.
We obtain that the solution of the system is:
[tex](x,y)=(1900,3100)[/tex]Therefore, there was invested $3100 in the account at 9% and 1900 in the account at 6%.