i know how x^2 +3x +10 has 2 roots by using the discriminant but how do we know that they are rational without solving the equation?
if the roots are integers they are factors of the constant term 10 . if they are rationals they are among the fractions you are forming combining 10 and the first coefficient a if it is not equal to 1.I suggest to study more the polynomials.
MINOAS
Suppose that each of $\displaystyle \alpha~\&~\beta$ is a root.
Then the quadratic is $\displaystyle (x-\alpha)(x-\beta)=0$ or $\displaystyle x-(\alpha+\beta)x+(\alpha\beta)=0$.
Now if each of $\displaystyle \alpha~\&~\beta$ is a rational number we can write that as $\displaystyle ax^2+bx+c=0$ where $\displaystyle a,~b,~\&~c$ are integers.
Clearly in $\displaystyle x^2 +3x +10=0$ the sum of the roots is $\displaystyle -3$ and the product is $\displaystyle 10$ .
If you have a quadratic with integral coefficients and the discriminant is not a perfect square what does that tell you?
Just find the discriminant, if it is positive then you will have two real and unequal roots. Further if the discriminant is a perfect square then we get two real, unequal and rational roots. If discriminant is equal to 0 we get two equal roots and if discriminant is negative the the equation will have no real roots but two imaginary roots. thus we need to just find the discriminant to know the nature of roots of quadratic equation