Answer
$y=\dfrac{t^3}{5}-\dfrac{12t^{-2}}{5}$
Work Step by Step
Here, we have $ty'+2y=t^3$
The integrating factor is: $I=e^{\int (2/t) dt}=t^2$
Now, $t^2[ty'+2y]=t^2 \cdot t^3$
This gives: $\int [t^2y]' dt=\int t^4$
$\implies t^2y=\dfrac{t^5}{5}+c$
Next, apply the initial conditions in the above equation, we have
$(1)(2)^2=\dfrac{(2)^5}{5}+c$ or, $c=-\dfrac{12}{5}$
Then, $t^2y=\dfrac{1}{5}t^5-\dfrac{12}{5}$
so, the general solution is:
$y=\dfrac{t^3}{5}-\dfrac{12t^{-2}}{5}$