$f(x)=\sin x$, $f$ polynomial $f$ is a polynomial and suppose that $f(x)=\sin x$ has infinitely many solutions. Prove that $f$ is a constant between -1 and 1.


I get the problem intuitively, but how would I prove this formally?

Can anyone give me any hints?
Not a High-School Level Solution:  First, we show that $f(x)=\sin(x)$ must have a solution for arbitrarily large $x$.  If not, then $f(x)=\sin(x)$ has infinitely many solutions on a compact subset of $\mathbb{R}$ (or $\mathbb{C}$).  By the Identity Theorem for Analytic Functions, as polynomials are analytic, we conclude that $f=\sin$, but this contradicts the assumption that $f$ is a polynomial (because $f$ would have infinitely many roots, making it the zero polynomial).  Hence, $f(x)=\sin(x)$ must have solutions with $|x|\to\infty$.  Then, use @newnewnewnewnenwwojpwjfpoergje's now deleted hint (I don't know why he deleted it, as it was a good hint).  If $f$ is nonconstant, then $\big|f(x)\big|\to\infty$ for $|x|\to\infty$, whence $f(x)=\sin(x)$ can't have arbitrarily large solutions $x$.
Assume that the polynomial is not constant.
we know that 
$\displaystyle{\lim_{x \rightarrow \pm \infty}}$f(x)=$\pm$ $\infty$ (f(x) is not constant,also it has a leading term) 
as f(x)  is a polynomial
for the equation f(x)=sinx to have infinitely many solutions f(x) must 
lie below $\pm$ 1 when x $\rightarrow$$\pm$$\infty$. 
But this is a contradiction.
Therefore f(x) is a constant function lying between $\pm$1.