subject
Computers and Technology, 11.11.2019 20:31 hey9691

Create a class named billing that includes three overloaded computebill() methods for a photo book store. • 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. 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}}

ansver
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 21:30, Nathaliasmiles
The graph shows median weekly earnings for full-time workers according to education level. which can you not conclude?
Answers: 2
image
Computers and Technology, 23.06.2019 23:30, issacurlyheadka
A. in packet tracer, only the server-pt device can act as a server. desktop or laptop pcs cannot act as a server. based on your studies so far, explain the client-server model.
Answers: 2
image
Computers and Technology, 24.06.2019 07:30, sunny644
John recently worked on a project about various programming languages. he learned that though procedural language programs are useful, they have disadvantages too. what is a disadvantage of programs written in procedural languages? a. programs do not represent data complexity. b. programs take more time to execute. c. programs are prone to security threats. d. programs do not interface with multiple platforms.
Answers: 3
image
Computers and Technology, 25.06.2019 07:30, ineedhelp2285
In a single day more than blank people's lives are affected simply by driving a motor vehicle
Answers: 1
You know the right answer?
Create a class named billing that includes three overloaded computebill() methods for a photo book s...

Questions in other subjects:

Konu
Engineering, 08.06.2021 18:40
Konu
History, 08.06.2021 18:40