Answered step by step
Verified Expert Solution
Question
1 Approved Answer
***** File: value_returning_function Purpose: This program determines the roots of a quadratic equation of the form: ax^2 + bx + c For the detailed explanation
***** File: value_returning_function Purpose: This program determines the roots of a quadratic equation of the form: ax^2 + bx + c For the detailed explanation regarding solving a quadratic equation, click View then select Show Explanation in the menu bar. ********** //include file... #include #include clomanip> #include using namespace std; //function prototype Provide the function prototype for FindRoots Provide the function prototype for Discriminant int main() //local variables float a, b, c // coefficient variables from formula char response; //Does the user want to process more equations? bool keepGoing; //Should the program process more roots? !/we want to process at least one set of data keepGoing = true; //Find roots of the quadratic equation until the user is finished while (cin 8:& keepGoing) { cout > >> >>C; //Determine the roots of the quadratic equation // Put your answer to #6 here cout > response: if (response == 'N' || response == m') keepGoing = false; } cout 0 Use the formulas to calculate two roots. assign larger root to root and smaller root to root2 cout
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started