It is true that
It's just like
Its a well known fact that
Var(X) = E(X^2) - (E(X))^2
but then can you conclude:
Var(X) = E(X^2) - (E(X))^2 = E(X^2) - E( E(X) X ) (because E(X) is a scalar)
= E[X^2 - E(X) X ] = E[ X ( X - E(X) ) ]
by linearity of expectation.
but also Var(X) = E[ (X- E(X))^2 ]
a contradiction no?
Clearly I must be doing something wrong?