1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Komok [63]
3 years ago
5

Given the following code, what will be the value of finalAmount when it is displayed? public class Order { private int orderNum;

private double orderAmount; private double orderDiscount; public Order(int orderNumber, double orderAmt, double orderDisc) { orderNum = orderNumber; orderAmount = orderAmt; orderDiscount = orderDisc; } public double finalOrderTotal() { return orderAmount - orderAmount * orderDiscount; } } public class CustomerOrder { public static void main(String[] args) { Order order; int orderNumber = 1234; double orderAmt = 580.00; double orderDisc = .1; order = new Order(orderNumber, orderAmt, orderDisc); double finalAmount = order.finalOrderTotal(); System.out.printf("Final order amount = $%,.2f\n", finalAmount); } } Group of answer choices
Computers and Technology
1 answer:
katrin [286]3 years ago
7 0

Answer:

$522.00

Explanation:

  • The code in Java implements two classes Order and CustomerOrder
  • The Order class contains the method for the member variables orderNum, orderAmount and orderDiscounts, It also contains the method finalOrderTotal() for calculating the final order amount
  • The second class CustomerOrder contains the main method and  serves as the driver class.
  • The finalAmount is calculated in the method finalOrderTotal()  and the logic here substracting the discount from the orderAmount that is orderAmount - (orderAmount * orderDiscount)
  • Since the orderAmount in the given example is 580 and the discount is 0.1 (i.e 58) the finalAmount will be 580 - 58 which gives 522 dollars
You might be interested in
When you are buying a computer, you must be careful to choose one with a pleasing desktop appearance because the way it looks is
fenix001 [56]

Answer:

False

Explanation:

You can always change the default look and feel of your Desktop appearance. To begin, right-click anywhere on the desktop and select personalize. A window will appear that will give you options to change your settings. You can choose various options like change the background, choose your own photos, and change colors.

8 0
3 years ago
1. Zack sees an online contest. He could win $10,000 instantly! On the sign-up form, he enters his name and email address. He is
Artyom0805 [142]

Answer:

1. Option B

2. Option B

3. Option B

Explanation:

Your mother's maiden name might be a password recovery question for your other personal account.

It is not legal to provide your SSN to any private entity.

Since the authenticity of the web site cannot be verified, it is not advisable to have business transactions with such websites.

6 0
3 years ago
3-D graphics are based on vectors stored as a set of instructions describing the coordinates for lines and shapes in a three-dim
svp [43]

Answer:

The correct answer to the following question will be "Wireframe".

Explanation:

  • A wireframe website, often recognized as a design link or computer diagram, is a graphic reference describing a website's architectural structure. They are built to organize items to help achieve a specific purpose.
  • It's a static, minimum-fidelity representation of various configurations that make up the item. It is indeed a visualization of an application that uses simple forms.

The correct answer to the following question will be "Wireframe".

5 0
4 years ago
To change the background color of a page, which tab would you use?
Digiron [165]
Format or file depends
5 0
3 years ago
Read 2 more answers
Who made the first sandwich?
RoseWind [281]
That guy made it. john m the 4th

7 0
3 years ago
Read 2 more answers
Other questions:
  • Ben chang noticed that his store was lagging in sales . He realized that his staff was not experienced enough . As the store man
    13·2 answers
  • Why do you think it is important to be responsible with financial information? Check all that apply.
    12·2 answers
  • Complex machines are defined by...
    14·2 answers
  • How is a source file different from a "listing file"?
    5·1 answer
  • I need help ASAP Asap asap!!!
    11·1 answer
  • Who are the key players in the internet
    10·1 answer
  • Outputting all combinations. Output all combinations of character variables a, b, and c using this ordering abc acb bac bca cab
    7·1 answer
  • 1. If Earth's plates are constantly moving, why don't we need to update the locations of -
    13·1 answer
  • To increase security on your company's internal network, the administrator has disabled as many ports as possible. Now, however,
    12·1 answer
  • Write a program that prompts the user to input an integer and then outputs both the individual digits of the number and the sum
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!