I'm starting on classical mechanics in university (second year) and I skipped first year physics. I do have quite a good mathematical knowledge but I'm not getting this question:

Verify by direct substitution that the function is a solution to the second order differential equation

(Since this solution involves two arbitary constants - the coefficients of the sine and cosine functions - it is in fact the general solution)

So I was just thinking of substituting the first equation into the second to get:

And then distribute and integrate twice to get the differential?

I'm really confused about the question.