Problem: Let $I$ be an interval and $x_0\in{I}$. Let $p:I\to\mathbb{R}$, $q:I\to\mathbb{R}$ be two continuous functions. Show there exists a unique differentiable function $f:I\to\mathbb{R}$ such that $f(x_0)=y_0$ and $$f'(x)+p(x)f(x)=q(x).$$I was able to prove that there was a solution given by $$f(x):=e^{-\int_{x_0}^x{p(s)ds}}\biggr{(}\int_{x_0}^x{e^{\int_{x_0}^t{p(s)ds}}q(t)dt}+y_0\biggr{)},$$ but when trying to prove uniqueness I got stuck. I see that you can use separation of variables but the textbook I'm reading through doesn't include that method so I don't know any of the rigour behind it. Besides that I can see no other way to solve the problem.
Thanks for any help.