$4000 was invested at 3% interest.
Solution:
Assume that x and y represent the amount at 3.5% and 3% respectively. So, according to the given statements we get two equations,
![x+y=5000\rightarrow(1)\\\\3x+3.5y=15500\rightarrow(2)](https://img.qammunity.org/2021/formulas/business/high-school/egdn9zmoqr1xi5jeikpccdkt16t3m0a2qi.png)
On multiplying equation (1) by 30 and equation (2) by 10 we get,
![30 x+30 y=150000\\\\30 x+35 y=155000](https://img.qammunity.org/2021/formulas/business/high-school/zaazipli85jqyquvc6ouvsayewlroqadax.png)
On solving both the equations we get,
![\Rightarrow5y=5000\rightarrow y=(5000)/(5)\rightarrow y=1000\rightarrow(3)](https://img.qammunity.org/2021/formulas/business/high-school/iqum8c18qgqsizrjjdehab2pyypoh61jtn.png)
On substituting (3) in (1) we get,
![\Rightarrow x+1000=5000\rightarrow x=5000-1000\rightarrow x=4000](https://img.qammunity.org/2021/formulas/business/high-school/76nnrknob25ymtxrih3co43fewpcabqe67.png)
Therefore, $4000 was invested at 3% interest and $1000 was invested at 3.5% interest.