If the sum and product of the roots are given:
Use the formula for sum which is
-b/a
Use the formula for product which is
c/a
If the roots are given:
There are two methods, for example 1, 5 and 12 are the roots
Method I
x=5 x=12
x-5=0 x-12=0
(x-5)(x-12)=0
x^2-17x+60=0
Method II
x1+x2=17 (x1)(x2)=60
-b/a= 17 c/a=60
x^2-17x+60=0