First we need to find the discriminant which is discriminant=b*b - 4*a*c. So , depending on the value of discriminant , we can find the roots easily .
If Discriminat D >0 the roots are real.
If D<0 , roots are imaginary
The formula for finding out the roots are root1=(-b+sqrt(b*b-(4*a*c))/(2*a))
We need to use the functions present in MATH.H header file. for this we need to include the <math.h> header file.
please have a look at the attached file to understand the program to supplement your understanding of the video file above.