According to me there are no bugs in y code for the input 1,1,1 as it is correctly printing Imaginary,plz check my code and revert, i will be grateful to you, thankz ,
#include
#include<math.h>
using namespace std;
int main()
{
int a,b,c,d;
float d1,x;
cin>>a>>b>>c;
d = ((bb)-(4ac));
d1 = pow(d,0.5);
if (d == 0)
{
cout<<“real and equal”;
x = (-b)/(2a);
cout<<" “<<x<<” "<<x;
}
else if (d < 0)
{
cout<<"Imaginary ";
}
else
{
cout<<“real and distinct” ;
x = (-b+d1)/(2a);
cout<< " "<<x;
x = (-b-d1)/(2a);
cout<< " "<<x;
}
return 0;
}