Find all polynomials $P \in \mathbb{R}[X]$ such that

$$
\left\{\begin{array}{l}
P(2)=2 \\
P\left(X^{3}\right)=P(X)^{3}
\end{array}\right.
$$
Let $P$ be a polynomial solution.

By evaluating at 2, we have $P(8)=8$. We can re-evaluate at $8 \ldots$ By induction, we get $P\left(2^{3 n}\right)=$ $2^{3 n}$ for $n \in \mathbb{N}^{*}$. This represents an infinity of points equal to the polynomial $X$ by rigidity, we thus have $P=X$.

Conversely, the identity works.