Question: 3. Quadratic Roots. Write a program groots.java that reads three floats a, b, c from the user and computes/prints the roots of the quadratic polynomial

 3. Quadratic Roots. Write a program groots.java that reads three floats

3. Quadratic Roots. Write a program groots.java that reads three floats a, b, c from the user and computes/prints the roots of the quadratic polynomial ax2 + bx + c = 0. Your program needs to handle only the case when real roots exist, i.e., when the values of a; b; c produce a non-negative discriminant b2 - 4ac > 0. When the discriminant is negative your program should only print a message that no real roots exist. > 1-3 2 1.0 2.0

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!