## Calculus (3rd Edition)

$c=-\frac{1}{2}$.
Since $y=x-2+e^{cx}$, then we have $y'=1+ce^{cx}$. Now, by substitution, we get $$2y'+y=2+2ce^{cx}+x-2+e^{cx}=x$$ which leads to $$(2c+1)e^{cx} =0$$ that is, $2c+1=0$ and hence $c=-\frac{1}{2}$.