The correct option is D If g[n] = 1 + (-1)n, then S is time invariant.
(a) g[n] = 1
g[n - 1] = 1
So, y[n] = x[n] [1 + 1]
= 2 x[n]
Thus system is time invariant
(b) g[n] = n
So, g[n - 1] = (n - 1)
Now, y[n] = x[n] [n + n -1]
x[n] [2n - 1] which is time variant.
(c) g[n]=1+(−1)n
g[n−1]=1+(−1)n−1
y[n]=x[n][1+(−1)n+1+(−1)n−1]
=x[n][2]
= 2x [n]
which is time invariant
(d) g[n] = δ[n]
g[n-1] = δ[n−1]
g[n]=x[n][δ[n]+δ[n−1]]
which is time variant.