In an exercise for uni I am asked to prove that $w^* \in \mathbb{R}^d$ is a solution to $\min_{w \in \mathbb{R}^d}\lVert y - Xw \rVert_{2}^{2}$ if and only if $X^\dagger X w^* = X^\dagger y$, where $X^\dagger$ is the pseudo-inverse of $X$ (https://en.wikipedia.org/wiki/Moore%E2%80%93Penrose_inverse).
My initial idea of solving this was by writing out the L2-norm expression, but I do not think this would help me, as this does not lead to an expression containing $X^\dagger$.
Could any of you help me with starting off this proof? thanks in advance!!