Question: 9 THE QUADRATIC PROBLEM Write a function named quadratic() that computes roots of quadratic equations. Recall that a quadratic equation is one of the form,
9 THE QUADRATIC PROBLEM Write a function named quadratic() that computes roots of quadratic equations. Recall that a quadratic equation is one of the form, ax' + bx + c = 0 Your function accepts five parameters: The integer coefficients a, b, and c as two input parameters .Two real number (double) output parameters rootl and root2. Your function should compute the two integer roots of the quadratic equation and store them into the two reference parameters. For example, the equation x2-3x-4-0 has roots of x = 4 and x =-1, so the call quadratic (1, -3, -4, root 1, root 2); should set root 1 to 4 and root2 to -1. You may assume that the function has two real roots. Recall the quadratic formula is: 2a
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
