#include <math.h>

#include <stdio.h>

int

main ()

{

int a, b, c;

float D;

int x;

printf ("enter the co-effecients of the equation : ");

scanf ("%d %d %d", &a, &b, &c);

D=ROOTS(a,b,c);

printf("%f",D);

if (D > 0)

{

printf ("\nthe roots are distinct and real \nroot 1 %.0f\nroot 2 %.0f",

(-b + D) / (2 * a), (-b - D) / (2 * a));

}

else if (D == 0)

{

printf ("\nthe roots are real and equal \nroot 1 %.0f\nroot 2 %.0f",

-b / (2 * a), -b / (2 * a));

}

else if (D < 0)

{

printf ("\nno real roots");

}

return 0;

}

int ROOTS(int l,int m, int n)

{

double E;

E = sqrt ((m * m) - (4 * l * n));

return(E);

}