I must prove that an hypersurface $M$ on $\mathbb{R}^{n+1}$ that is Einstein and compact can be only the $n-$dimensional sphere when $n>2$
The Einstein condition we permits to say that scalar curvature of $M$ is costant because $n>2$. The fact that it is an hypersfurface of $\mathbb{R}^{n+1}$ can be use to consider the gauss equation and the Codazzi-Mainardi equation. The fist equation we say that
$H^2-|h|^2=cost=R^M$
Where $H$ is the mean curvature and $h$ is the second fundamental form of $M$.
In the case in which $n=3$ we have that
$cost=H^2-|h|^2=2\lambda\mu=2\det(h)$
So the Gaussian curvature of $M$ is costant but $M$ is compact so it is the 2-sphere on $\mathbb{R}^3$.
How can conclude in the case in which $n>3$?