Maurice Tutor

(5)

$15/per page/Negotiable

About Maurice Tutor

Levels Tought:
Elementary,Middle School,High School,College,University,PHD

Expertise:
Algebra,Applied Sciences See all
Algebra,Applied Sciences,Biology,Calculus,Chemistry,Economics,English,Essay writing,Geography,Geology,Health & Medical,Physics,Science Hide all
Teaching Since: May 2017
Last Sign in: 398 Weeks Ago, 2 Days Ago
Questions Answered: 66690
Tutorials Posted: 66688

Education

  • MCS,PHD
    Argosy University/ Phoniex University/
    Nov-2005 - Oct-2011

Experience

  • Professor
    Phoniex University
    Oct-2001 - Nov-2016

Category > Computer Science Posted 16 Jul 2017 My Price 6.00

quadratic equation

Write a program that uses the following subroutine, from Subsection 8.3.3, to solve equa- (solution)tions specified by the user./*** Returns the larger of the two roots of the quadratic equation* A*x*x + B*x + C = 0, provided it has any roots. If A == 0 or* if the discriminant, B*B - 4*A*C, is negative, then an exception* of type IllegalArgumentException is thrown.*/static public double root( double A, double B, double C )throws IllegalArgumentException {if (A == 0) {throw new IllegalArgumentException("A can’t be zero.");}else {double disc = B*B - 4*A*C;if (disc < 0)throw new IllegalArgumentException("Discriminant < zero.");return (-B + Math.sqrt(disc)) / (2*A);}}Your program should allow the user to specify values for A, B, and C. It should call thesubroutine to compute a solution of the equation. If no error occurs, it should print theroot. However, if an error occurs, your program should catch that error and print an errormessage. After processing one equation, the program should ask whether the user wantsto enter another equation. The program should continue until the user answers no.

Answers

(5)
Status NEW Posted 16 Jul 2017 09:07 PM My Price 6.00

Hel-----------lo -----------Sir-----------/Ma-----------dam----------- Â----------- Th-----------ank----------- Yo-----------u f-----------or -----------usi-----------ng -----------our----------- we-----------bsi-----------te -----------and----------- ac-----------qui-----------sit-----------ion----------- of----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n. -----------Ple-----------ase----------- pi-----------ng -----------me -----------on -----------cha-----------t I----------- am----------- on-----------lin-----------e o-----------r i-----------nbo-----------x m-----------e a----------- me-----------ssa-----------ge -----------I w-----------ill-----------

Not Rated(0)