c++. ----------- Question 4: Prompt the user to input 3 doubles, a, b and c, which will
Fantastic news! We've Found the answer you've been seeking!
Question:
c++. -----------
Transcribed Image Text:
Question 4: Prompt the user to input 3 doubles, a, b and c, which will represent the coefficients in the quadratic equation ax² +bx+c = 0. Print out the solutions (if any) of the quadratic equation. If no root exists (this happens if a == 0, or b² <4ac) print the message No real root. Sample input/ user entries shown in red Enter a, b and с which represent the Rootl is coefficients in the quadratic equation ax^2 +bx+c = 0:1 0-8 Corresponding output 2.828427 Root2 is -2.828422 Enter a, b and с which represent the coefficients in the quadratic equation ax^2 +bx+c = 0 : 0 35 Enter a, b and с which represent the Rootl is 0.854101 coefficients in the quadratic equation ax^2 Root2 is -5.854101 +bx+c = 0 : 15-5 Your test plan may not contain any of the values used in the example, above. No real root Question 4: Prompt the user to input 3 doubles, a, b and c, which will represent the coefficients in the quadratic equation ax² +bx+c = 0. Print out the solutions (if any) of the quadratic equation. If no root exists (this happens if a == 0, or b² <4ac) print the message No real root. Sample input/ user entries shown in red Enter a, b and с which represent the Rootl is coefficients in the quadratic equation ax^2 +bx+c = 0:1 0-8 Corresponding output 2.828427 Root2 is -2.828422 Enter a, b and с which represent the coefficients in the quadratic equation ax^2 +bx+c = 0 : 0 35 Enter a, b and с which represent the Rootl is 0.854101 coefficients in the quadratic equation ax^2 Root2 is -5.854101 +bx+c = 0 : 15-5 Your test plan may not contain any of the values used in the example, above. No real root
Expert Answer:
Answer rating: 100% (QA)
include include using namespace std int main double a b c d r1 r2 cou... View the full answer
Related Book For
Introduction to Java Programming, Comprehensive Version
ISBN: 978-0133761313
10th Edition
Authors: Y. Daniel Liang
Posted Date:
Students also viewed these electrical engineering questions
-
C plc wants to reward its directors for their service to the company and has designed a bonus package with two different elements as follows. The directors are informed of the scheme and granted any...
-
C and D agree to form a partnership. C is to contribute $50,000 in assets and to devote one-half time to the partnership. D is to contribute $20,000 and to devote full time to the partnership. How...
-
C Co. reported a retained earnings balance of $370,000 on December 31, 2017. In September 2018, C determined that insurance premiums of $54,000 for the three-year period beginning January 1, 2017,...
-
Is the State of Michigan justified in advertising the prize amount as $1.586 billion? Explain.
-
Evaluate the impact of the following proposed mergers upon the postmerger earnings per share of the combined organization: a. An acquiring bank reports that the current price of its stock is $25 per...
-
(Objectives of Financial Reporting) Karen Sepan, a recent graduate of the local state university, is presently employed by a large manufacturing company. She has been asked by Jose Martinez,...
-
A company is considering two alternatives, one of which must be implemented. Of the two projects, A has the higher maintenance cost, but B has the higher investment cost. The appropriate (and...
-
Prior to the distribution of cash to the partners, the accounts in the NJF Company are: Cash $28,000, Newell Capital (Cr.) $17,000, Jennings Capital (Cr.) $15,000, and Farley Capital (Dr.) $4,000.The...
-
1. An object of mass of 4 kg is resting at a height of 2 m and then falls to the ground. a. Model the energy of the object-Earth system with Energy Bar Charts when at the initial height and ground...
-
State Bank's balance sheet is listed below. Market yields and durations (in years) are in parenthesis, and amounts are in millions. a. What is the repricing gap if the planning period is six months?...
-
An experimental procedure for standardization of the titrant states the following: Weigh accurately, about 0.26-0.27 g of the primary-standard. Record the mass to the nearest 0.0001 g. Which mass...
-
Describe how you would collaborate with the child's family to implement the short-term goal and strategies you've identified. These are my short term goals: Short-term goal: Learn to recognize the...
-
Can someone please help me with Dynamic Binding. This is my 5th time trying to get a program running but I have been late due to personal issues. I wanted to make a dynamic binding program based on a...
-
1. Cherry Auto Sales just opened and does not expect to pay a dividend during its first year. At the end of its second year, Cherry's owners expect to pay a $2.00 dividend and plan to increase it 7%...
-
One assumption of the case is that were the hotel to outsource laundering of banquet linen, the cost they would incur per tablecloth would be directly linked to the amount of banquet linen laundered....
-
If the GBP/USD rate is 1.3450, how much GBP can $1 million USD buy? 1. 743,494 GBP 2. 1,345,000 GBP 3. 1,340,000 GBP 4. 863,976 GBP
-
Solve the set of lincar equations with the LU Factorization Method (Triangulation Method) 2x1 + x2 5x1 - 2x +x2 3x3 Note: Show what you have done in your calculations at every step in detail....
-
One study found that the elderly who do not have children dissave at about the same rate as the elderly who do have children. What might this finding imply about the reason the elderly do not dissave...
-
Write a JSF page that lets the user enter loan amount, interest rate, and number of years, as shown in Figure 33.28a. Click the Compute Loan Payment button to compute and display the monthly and...
-
Programming Exercise 5.26 approximates e using the following series: In order to get better precision, use BigDecimal with 25 digits of precision in the computation. Write a program that displays the...
-
Modify the GeometricObject class to implement the Comparable interface, and define a static max method in the GeometricObject class for finding the larger of two GeometricObject objects. Draw the UML...
-
______________ refers to the location, time, and occasion where communication occurs.
-
Identify the four steps of the KEYS process.
-
______________ is the general term for the discussion, determination, and deliberation processes that attempt to decide what is right or wrong, what others should or should not do, and what is...
Study smarter with the SolutionInn App