Suppose that the roots of $x^2+px+q=0$ are rational numbers and $p,q$ are integers... Suppose that the roots of $x^2+px+q=0$ are rational numbers and $p,q$ are integer, then show that the roots are integers.
My work:
Let the roots be $\frac{m}{n}$ and $\frac{m'}{n'}$.
Now, sum of the roots: $\frac{m}{n}+\frac{m'}{n'}=-p$
It implies that $-p=\dfrac{mn'+m'n}{nn'}$
Product of the roots: $\dfrac{mm'}{nn'}=q$
Now, $gcd(m,n)=1$ and $gcd(m',n')=1$  
So,here I reach a point where I cannot go any further. Please help!
 A: By the quadratic formula, the roots are equal to $$\frac{-p\pm\sqrt{p^2-4q}}{2}$$
So, since the square root and $p$ are both integers (since otherwise the roots are not rational). But these two integers are either both even or both odd (why?), and therefore their sum or difference is always even - hence your claim.
A: Check out the Rational Root Theorem (and proof thereof).
A: Here is a direct proof a bit different from the standard proof of the Rational Root Test.
Theorem $\,\ $ If $\rm\,\ r^2 =\, \color{#0A0}{p\, r + q}\ \,$ for $\rm\ p,\,q\in\mathbb Z\ $ then $\rm\ r\in \mathbb Q\ \Rightarrow\ r\in\mathbb Z$
Proof $\ \ \ \rm \color{blue}{r\, =\, a/b}\in \mathbb Q,\ \, \gcd(a,b) = 1\ \Rightarrow\ ad\!-\!bc \;=\; \color{#C00}{\bf 1}\;$  for some $\:\rm c,d \in \mathbb{Z}\;\;$ by Bezout. 
So $\rm\,\ 0\, =\, (\color{blue}{a - br})\: (c\!+\!dr) \, =\, ac\! -\! bd(\color{#0A0}{p\,r + q})+\color{#C00}{\bf 1}\cdot r \, =\, ac\!-\!adp\!-\!bdq +  r \ \Rightarrow\ r \in \mathbb{Z}\ \ $ QED 
Remark $\ $ This degree reduction generalizes to higher degree. If $\rm\ r = a/b \in \mathbb Q\ $ is the root of a monic polynomial $\in \mathbb Z[x]\:$ of degree $> 1$ then we can construct a lower degree monic polynomial having $\rm\:r\:$ as root - precisely as we did above. This degree reduction implies that we can prove irrationality of cube roots from the irrationality of square roots - something not well-known.
A: $\frac{m}{n}$ is a root and $\gcd(m,n)=1$. We have 
$$(\frac{m}{n})^2 = -p \frac{m}{n} - q$$
If we multiply this equation by $n$ we get
$$\frac{m^2}{n} = -p m - q n$$
The left-hand side and therefore the right-hand side is an integer. So $n$ must be $1$.
A: $$\frac{m^2}{n^2}+p\frac{m}{n}+q = 0 \Rightarrow m^2 + p m n + q n^2=0$$
If $s$ is a any prime dividing $n$, then 
$$
s | (q n^2 + p m n ) \Rightarrow s | m^2 \Rightarrow s|m$$
If $m$ and $n$ are co-prime then no prime divides $n$, or $n=1$. Thus the root has to be an integer.
Note: 


*

*This is true for any degree polynomial as long as the leading coefficient is 1 and all coefficients are integers.

*Even more generally, of $m/n$ is a root and all the coefficients are integers, then $n$ divides the leading coefficient.

