Consider
$$y''(t) + \lambda y(t) = 0$$
Setting $y=e^{rt}$
$$y = c_1e^{i\sqrt{\lambda}t} + c_2e^{-i\sqrt{\lambda}t}$$
Using Euler's identity
$$y= c_1\left[\cos\sqrt{\lambda} t + i \sin\sqrt{\lambda} t \right] + c_2\left[\cos\sqrt{\lambda} t - i \sin\sqrt{\lambda} t \right]$$
How do we get rid of the $i$ to get our "standard-looking" general solution?
Note that $$y_1= \left[\cos\sqrt{\lambda} t + i \sin\sqrt{\lambda} t \right]$$
and $$y_2 =\left[\cos\sqrt{\lambda} t - i \sin\sqrt{\lambda} t \right]$$
are solutions to your linear differential equation.
Thus the sum and the difference of $y_1$ and $y_2$ are also solutions. $$ \frac { y_1+y_2}{2} = cos \sqrt{\lambda} t $$ and $$ \frac {y_1-y_2}{2i} = sin\sqrt{\lambda} t $$ Now the general solution is a linear combination of these two solutions.
That is $$y= C_1 cos\sqrt{\lambda} t + C_2 \sin\sqrt{\lambda} t $$