Minimizing Expected Value I have a problem which wants the c value that minimizes E[(X-c)2]

I started with 

E[(X-c)2] = E[X]2 -2cE[X] + c2



but couldn't continue on this. Could you please help me on finishing this problem.

Thanks in advance.
Hint: 

$$\dfrac{d}{dc}E[(X-c)^2] = -2E[X]+2c$$ so find  the value of $c$ that gives the minimum in the usual way
Take derivates wrt to $c$, treating any term without $c$ in it as a constant, thus differentiates to zero. 

When differentiating just treat $E[X]$ as a function of $x$ and then differentiate as normal with the chain rule.