Step 1:

Given : $y = e^x(a\cos x + b\sin x)$

Differentiating on both sides by applying the product rule we get,

$y' = e^x(a\cos x + b\sin x) + e^x(-a\sin x + b\cos x)$

$y - y' = e^x(b\cos x - a\sin x)$------(1)

Step 2:

Again differentiating y' on both sides we get

$y'' = e^x(a\cos x +b\sin x) + e^x(-\sin x + b\cos x) + e^x (-a\sin x + b\cos x) - e^x(a\cos x + b\sin x)$

On simplifying we get

$y'' = 2e^x(b\cos x - a\sin x)$

Substituting equ(1) we get y'' = 2(y' - y)

$y'' -2y' +2y = 0$