subject

Modify code below; public class Billing {

final static double TAX = 0.08;

public static void main(String[] args) {

final double HIGHPRICE = 24.99;

final double MEDPRICE = 17.50;

final double LOPRICE = 10.00;

final int QUAN1 = 4;

final int QUAN2 = 6;

double bill;

bill = computeBill(HIGHPRICE);

System. out. println("The total for a photobook that costs $" +

HIGHPRICE + " is $" + bill);

bill = computeBill(MEDPRICE, QUAN1);

System. out. println("The total for " + QUAN1 +

" photobooks that cost $" +

MEDPRICE + " is $" + bill);

bill = computeBill(LOPRICE, QUAN2, 20.00);

System. out. println("The total for " + QUAN2 +

" photobooks that cost $" +

LOPRICE + " with a $20 coupon is $" + bill);

}

public static double computeBill(double amt) {

// Write your code here

}

public static double computeBill(double amt, int quantity) {

// Write your code here

}

public static double computeBill(double amt, int quantity, double coupon) {

// Write your code here

}

}

Remember: double total = amount + amount * taxrate;

• When computeBill() receives a single parameter, it represents the price of one photo book ordered. Add 8% tax, and return the total due.

• When computeBill() receives two parameters, they represent the price of a photo book and the quantity ordered. Multiply the two values, add 8% tax, and return the total due.

• When computeBill() receives three parameters, they represent the price of a photo book, the quantity ordered, and a coupon value. Multiply the quantity and price, reduce the result by the coupon value, and then add 8% tax and return the total due.

can someone please explain this to me when you write the answer? please and thank you.
just do an sample problem instead of the actual problem so i understand it more better.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 08:30
When you interpret the behavior of others according to your experiences and understanding of the world your evaluation is
Answers: 1
question
Computers and Technology, 24.06.2019 08:30
Formatting rows and columns is similar to cell formatting. in an openoffice calc spreadsheet, you can format data entered into rows and columns with the of the rows and columns options. you can insert rows and columns into, or delete rows and columns from, a spreadsheet. use the insert or delete rows and columns option on the insert tab. alternatively, select the row or column where you want new rows or columns to appear, right-click, and select insert only row or only column options. you can hide or show rows and columns in a spreadsheet. use the hide or show option on the format tab. for example, to hide a row, first select the row, then choose the insert tab, then select the row option, and then select hide. alternatively, you can select the row or columns, right-click, and select the hide or show option. you can adjust the height of rows and width of columns. select row and then select the height option on the format tab. similarly, select column, then select the width option on the format tab. alternatively, you can hold the mouse on the row and column divider, and drag the double arrow to the position. you can also use the autofit option on the table tab to resize rows and columns.
Answers: 1
question
Computers and Technology, 24.06.2019 11:00
In three to five sentences, describe how you can organize written information logically and sequentially
Answers: 1
question
Computers and Technology, 24.06.2019 18:30
Is a type of bullying that takes place when a person intentionally posts negative information about another person that is not true.
Answers: 2
You know the right answer?
Modify code below; public class Billing {

final static double TAX = 0.08;

p...
Questions
question
Biology, 03.03.2021 22:40
question
Mathematics, 03.03.2021 22:40
question
Mathematics, 03.03.2021 22:40
question
Chemistry, 03.03.2021 22:40
question
Mathematics, 03.03.2021 22:40
question
Mathematics, 03.03.2021 22:40
question
English, 03.03.2021 22:40
Questions on the website: 13722363