Объяснение:
#include <iostream>
#include <math.h>
using namespace std;
int main()
{
int a, b, c, d;
cout <<"vvedite a, b , c" << endl;
cin >> a >> b >>c;
if(a == 0.0)
{
cout << "a ravo 0!" << endl;
return 0;
}
d = b*b - 4 * a * c;
if(d < 0)
{
cout << "net kornei" << endl;
return 0;
}
if(d == 0)
{
cout << "odin koren, x = " <<(-b)/2*a <<endl;
return 0;
}
cout << "dva korna, x1 = " <<(-b + sqrt(d))/2*a << " x2 = " <<(-b - sqrt(d))/2*a << endl;
return 0;
}