# [SOLVED] proving a theorem regarding expected value

prove that $E[X-E(X)]^2 = E(X^2)-[E(X)]^2$
prove that $E[X-E(X)]^2 = E(x^2)-[E(x)]^2$
$E\left( {\left[ {X - E(X)} \right]^2 } \right) = E\left( {X^2 - 2XE\left( X \right) + E^2 \left( X \right)} \right)$ $= E\left( {X^2 } \right) - 2E\left( X \right)E\left( X \right) + E^2 \left( X \right) = E\left( {X^2 } \right) - E^2 \left( X \right)$