**Program 1**

Write a java program to compute both roots of the quadratic equation with the user provides the three coefficients A, B and C.

Specifically,

A. Display your name

B. Display Project_2 Problem_1

C. Display This program computes both roots of a quadratic equation

D. Display given the coefficients A,B and C

E. Real_1=0

F. Real_2=0

G. Imag=0

H. D=0

I. DD=0

J. Flag='Y'

K. Do

*Display "Enter A"*

*Display "Enter B" *

*Display "Enter C"*

*keyboard.nextLine();*

*D = (math.pow(B,2.0)-4*A*C)*

*if D < 0 Then*

* DD=math.sqrt(4*A*C - B*B)*

*continued....*

**Program 2**

Write a java console program to compute the amount of change to be returned to a customer indicating the minimum number of dollars, quarters, dimes, nickels, and pennies. I am providing most of the code below, you need to finish the software.

//Project_2 Problem_2

*import java.util.scanner*

*public class Proj_2_Prob_2*

*{*

* public static void main(String[] args){*

* System.out.println("Your name");*

* System.out.println("Project_2 Problem_2");*

* System.out.println("This program computes the number of dollar bills");*

* continued ...*

* }*

*}*

By looking at the calculation code above and seeing the pattern complete the rest of the calculation software.

Display the results

Complete the DO LOOP- use the items highlighted in RED for Problem_1 for help.

This assignment has been answered **6 times** in private sessions.

© 2020 Codify Tutor. All rights reserved