subject

Please debug the below code in Java please.
// The Invoice class contains invoice number, customer name,// balance due, and tax owed fields,// and methods to set and display the values.// The invoice number must be between 1000 and 9999 inclusive// or else it is set to 0// Tax is 7 % of the balance due// The demonstration program instantiates three Invoices and// purposely assigns invalid values to some of the arguments;// the class methods will correct the invalid values. class Invoice Declarations private num invoiceNumber private string customer private num balanceDue private num tax private void setInvoiceNumber(num number) Declarations num LOW_NUM = 1000 num HIGH_NUM = 9999 if number > HIGH_NUM then invoiceNumber = 0 else if number < LOW_NUM then invoiceNumber = 0 else invoiceNumber = number endif endif return private void setCustomer(string cust) customer = cust return public void setBalanceDue(num balance) balanceDue = balance setTax() return private void setTax(num balanceDue) Declarations num TAX_RATE = 0.07 tax = balanceDue * TAX_RATE return public void displayInvoice() output "Invoice #", invoiceNumber output "Customer: ", customer output "Due: ", balanceDue output "Tax: ", tax output "Total ", balance + tax returnendClassstart Declarations Invoice inv1 Invoice inv2 Invoice inv3 inv1.setInvoiseNumber(1244) inv1.setCustomer("Brown") inv1.setBalanceDue(1000.00) inv1.displayInvoice() inv2.setInvoiceNumber(77777) inv2.setCustomer("Jenkins") inv2.setBalanceDue(2000.00) inv2.displayInvoice() inv3.setInvoiceNumber(888) inv3.setCustomer("Russell") inv3.setBalanceDue(3000.00) inv3.displayInvoice()stop

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 16:10
When copying and pasting text, the first step is move your cursor type the text select the copy command select the paste command
Answers: 2
question
Computers and Technology, 24.06.2019 01:10
Create a program that will take in a single x and y coordinate as the origin. after the input is provided, the output should be all of the coordinates (all 26 coordinates read from the “coordinates.json” file), in order of closest-to-farthest from the origin.
Answers: 1
question
Computers and Technology, 24.06.2019 09:30
Retype the statements, correcting the syntax errors. system.out.println("num: " + songnum); system.out.println(int songnum); system.out.println(songnum " songs"); note: these activities may test code with different test values. this activity will perform two tests: the first with songnum = 5, the second with songnum = 9. see how to use zybooks.
Answers: 1
question
Computers and Technology, 24.06.2019 13:30
Which of the following is not a “fatal four” event?
Answers: 2
You know the right answer?
Please debug the below code in Java please.
// The Invoice class contains invoice number, cust...
Questions
question
English, 28.07.2019 08:30