/* quad_root.cpp This program takes in the three coefficients a, b and c of a quadratic equation ax^2 + bx + c =0 and outputs the real roots of the equation. Written by: Maranda Bean */ #include #include using namespace std ; int main() { //for setting the nunmber of digits to be displayed after the decimal point. int n_digits = 4; cout.setf(ios::fixed); cout.setf(ios::showpoint); cout.precision(n_digits); cout<< "This program takes in the three coefficients a,b and c of a quadratic equation ax^2 + bx + c =0 and outputs the real roots of the equation."<> a >> b >> c ; cout << "You entered a= " << a << ", b = " << b << " and c = " << c << endl; if (a==0){ if (b!=0) cout<<"This equation has only one root, "<< -c/b <