If $f\in\mathbb{Q}[X]$ and $f(\mathbb{Q})=\mathbb{Q}$ then $\deg f=1$ Could you give me any hint how to prove that  if $f\in\mathbb{Q}[X]$ and $f(\mathbb{Q})=\mathbb{Q}$ then degree of $f$ is equal to $1$? I have tried to prove it by using Bézout's theorem but I guess it is not the best way to do it... Thanks in advance.
 A: Presumably the solution below is not the intended one.  Perhaps you can translate the idea into one more algebraic in spirit.
Suppose that $f$ has degree $\ge 2$. Without loss of generality we may assume that $f$ has positive lead coefficient, and integer coefficients.  Note that $f$ must have odd degree, else $f$ misses all large enough negative rationals.
Suppose that the lead coefficient of $f$ is $a$, and the constant term is $c$.  Finally, let $p$ be a very large prime.
We look at the equation $f(x)=p+c$, and show that it has no rational roots, meaning that $f(\mathbb{Q})$ misses $p+c$.  By the Rational Roots Theorem, any such root has to be of the form $\pm 1/d$ or $\pm p/d$, where $d$ is a divisor of $a$.  The negative possibilities can be discarded, as can $1/d$ (too small), so any rational solution has to be $\ge p/a$.  This is impossible, for when $p$ is huge, $f(p/a)$ is much larger than $p$ if $f$ has degree $\ge 2$. 
A: Since there already is one complete answer:
Suppose that $f$ has degree $k\ge 2$. Without loss of generality we may assume that $f$ has integer coefficients. Let $p$ be a prime that is not a factor of the leading coefficient, and assume there is an $x$ such that $f(x)=1/p$. Let us say that $x=m/n$ in lowest terms. Then
$$f(x)=\frac{a_km^k+a_{k-1}m^{k-1}n+\cdots+a_0n^k}{n^k}$$
For this to equal $1/p$, clearly $p$ must divide $n^k$ and thus also $n$ itself. But then actually $p^k$ divides the denominator, so $p^{k-1}$ must divide the numerator. All terms except the first are multiples of $p$, so $p$ must also divide $a_km^k$. However neither $a_k$ nor $m^k$ is divisible by $p$, and since $p$ was prime this is a contradiction. Thus $1/p \not\in f(\mathbb Q)$.
