Question: Rstudio 4. Write a function (findQuadraticRoots) that returns the number of real roots of a quadratic equation a x*+b-x+c-0 and retums the values of the

RstudioRstudio 4. Write a function (findQuadraticRoots) that returns the number of real

4. Write a function (findQuadraticRoots) that returns the number of real roots of a quadratic equation a x*+b-x+c-0 and retums the values of the real roots. The three input arguments are the coefficients a, b, and c, and the output is a list with two items: a real number (num real) and a vector (roots vec containing the roots. Based on the discriminant D given by the equation, descrim b-4-a c possible function outputs are the following i. If descrim >0, num real

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!