Question: Fix the following code and use it to find the two roots for the quadratic equation X 2 + 10X- 11: // Program UseFunctions demonstrates
Fix the following code and use it to find the two roots for the quadratic equation X 2 + 10X- 11: // Program UseFunctions demonstrates the use of library and // user-defined functions. #include #include using namespace std; float Answer(float, float, float); int main () { cout << fixed << showpoint; cout << Answer(______, ______, _______); return 0; } float Answer(float one, float two, float three) { return ((- two + sqrt(pow(two, 2) - (4.0 * one * three))) / (2.0 * one)); }
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
