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
Mama L [17]
3 years ago
5

Write a class called Cashier that directs a cashier how to cash goods and give change to customers. The typical cashier operatio

ns are as follows: (a) Cashier clears the cash register machine. (b) Cashier enters the name and the price of each item in the cash registering machine. (c) The customer tenders an amount of money to pay for the goods (We assume the amount covers the total). (d) The cash machine computes: a. The number of items purchased b. The total amount of purchase c. The average price of each item d. The number of coin denominations that the customer should receive. That is, the number of silver dollars, quarters, dimes, nickels, and cents the customer should receive in turn java
Business
1 answer:
worty [1.4K]3 years ago
5 0

Class Cashier that directs a cashier how to cash goods and give change to customers based on cashier operations is given below.

Explanation:

Use the following class, TestCashier, as the basis for the test class.

class TestCashier

{

public static void main(String[] arg)

{

Cashier c = new Cashier();

String name = GetData.getWord(“Enter name of item”);

double price = GetData.getDouble(“Enter price of item”);

c.add(name, price);

name = GetData.getWord(“Enter name of item”);

price = GetData.getDouble(“Enter price of item”);

c.add(name, price);

// Add a two more entries of your own

// Now average the price of the items

c.average();

// Make payment

double amount = GetData.getDouble(“Enter amount of money for payment”);

c.tendered(amount); // For example twenty dollars were tendered

c.makeChange();

generateReceipt(c);

}

static void generateReceipt(Cahier c)

{

// Write the necessary code that will generate a customer’s receipt.

// The output must be displayed in a scrollable pane

}

}

Description of the output:

The output should be displayed in a scrollable pane, and have the following features:

• The first line displays the name of the establishment.

• Second line reads something like this: Welcome – thanks for stopping, followed by the current date

• The list of items displayed, one item per line – That is, the name of the product and price,

• The sum of all the items

• The number of items purchased

• The average price for each item

• The amount of money tendered

• The amount of change in $ and cents

• The change given in coin denominations

Here is an example of the form of how the output should be ( except that this output must be displayed in a scrollable pane).

Bread............ 2.99

Chicken..........6.79

Egg..................3.07

______________

Total ……….$12.85

The number of items purchased is 3 items

The average price per item is $4.28

Amount tendered is $20.00

The change is $7.15

The change includes

7 dollars

0 quarters

1 dimes

1 nickels

0 cents

You might be interested in
All of the following are characteristics of a perfectly competitive market except: Group of answer choices barriers to entry per
Vesna [10]

Answer:

barriers to entry

Explanation:

The characteristics or attributes of the perfectly competitive market are as follows

1. There are large number of buyers and seller who purchase and sales similar kind of products

2. No transaction is involved

3. No barrier for entry and exit into the market

4. It contains the perfectly elastic demand

5. Perfect knowledge about the products

Therefore the first option is considered

7 0
3 years ago
Advantage of
Allushta [10]
Market penetration- quick diffusion and adoption of your product in the marketplace, incentives to be efficient, discouragement of competition and creation of goodwill

proud to development- keeping pace, seizing opportunities, providing opportunities and being newsworthy

market development- gaining new customers, increased revenue and company growth

diversification- minimizing risk of loss, preserving capital and generating returns
3 0
3 years ago
Frank age 63 is single and provided all of the support for his daughter Anna age 24 and her son Marvin age 6. Neither Anna nor M
allsm [11]

Frank cannot claim Anna or Marvin as a dependent.

Explanation:

Because Frank gives Anna and Marvin every support, support tests are straightforward.

Anna earns revenue in excess of $4200 and can not therefore be requested as dependent. In fact, Marvin does not stay with Frank and can not therefore be stated as dependent.

The income tax credit, EITC or EIC is a bonus to low- and moderate-income employers. To apply, you must fulfill certain criteria and file a tax report, even if you are not obliged to pay a bill. The level of tax you pay is lowered by the EITC and a refund is probable.

3 0
3 years ago
Adham is interested to buy a pair of shoes, at Lazzado.com as follows:
nlexa [21]
I think it could either be the first or third option, but I thinking the correct one should be the first option. Hope this helped :)
7 0
3 years ago
Able Trucking Corporation files a suit in a state court against Bob’s Service Company (BSC), and wins. BSC appeals the court’s d
xz_007 [3.2K]

Answer:

Explanation:

An appellate court will reverse a lower court’s decision on the basis of the facts only

when the finding is clearly erroneous (that is, when it is contrary to the evidence

presented at trial) or when there is no evidence to support the finding. Appellate courts

normally defer to a trial court’s decision with regard to the facts of a case, however, for

several reasons. First, trial court judges and juries have the opportunity to observe

witnesses and tangible evidence first hand. The appellate court sees only a cold record of

the trial court proceedings and therefore cannot make the kind of judgments about the

credibility of witnesses and the persuasiveness of evidence that can be gleaned only from

firsthand experience. Second, as occurs when there is no jury and the case is heard by a

judge, trial judges routinely sit as fact finders. As a result, they develop a particular

expertise in determining what kind of evidence and testimony is reliable and what kind is not

3 0
3 years ago
Other questions:
  • All of the following are career myths that influence people’s perception of how important career explorations are for an individ
    5·1 answer
  • Suppose you deposit $125 into an account at the end of every month. If the account earns 6% interest, compounded monthly, how lo
    10·1 answer
  • If the demand increases by 100%, annual production will have to increase to jaw-breakers next year to meet the expected increase
    13·1 answer
  • This department administers the food stamp program which provides coupons to needy families to increase their food purchasing po
    9·1 answer
  • Dahia comes to the conclusion while reviewing her presentation that she has left out key information in order to shed a better l
    11·2 answers
  • The following units are available for sale during the year:
    5·1 answer
  • Assume that instead, the debtholders had negotiated a covenant based on the maximum amount of investment (so, they set a maximum
    10·1 answer
  • Company A has been experiencing lost sales and high returns recently, so they have decided to undertake a comprehensive quality
    6·1 answer
  • Niat ny mau bikin dua akun tapi malah kesasar :(​
    14·1 answer
  • On December 31, Jarden Co.'s Allowance for Doubtful Accounts has an unadjusted credit balance of $16,500. Jarden prepares a sche
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!