Sentinel-controlled repetition to allow a user

Assignment Help Basic Computer Science
Reference no: EM13164514

Define method headers for computeAverageSales() and computeShipping Charges() according to the following requirements.

The computeAverageSales() method should use sentinel-controlled repetition to allow a user to enter product sales data until the user has indicated that he or she is done. The average of the entered sales data will be computed and returned by the method to be displayed by the application. For example, if the user entered 500.50, 250.50, and 300.30, then the average sales would be computed for these 3 values and returned by the method. The prompting of the sales data is done within the method. If the value of the average sales exceeds, $200.00, a message should be displayed to alert the user that the product has produced a significant amount of revenue. The computeAverageSales() method should return type "double."

The computeShippingCharges() method should use sentinel-controlled repetition to allow a user to enter shipping data until the user has indicated that he or she is done. The total shipping charges will be computed and returned as a double value.

Reference no: EM13164514

Questions Cloud

State what is the molarity of the diluted koh solution : 30.0 mL of a 3.0 M KOH solution are diluted to 250.0 mL. What is the molarity of the diluted KOH solution? 3)what volume of 1.00 M NaOH is required to prepare 500.0 mL of 0.250 M NaOH? then explain how to prepare this solution.
How many different undirected graphs are there with v vertix : Graph enumeration: How many different undirected graphs are there with V vertices and E edges (and no parallel edges)? Assume the graph is represented in adjacency-list form
State chemiluminescence has been shown to increase linearly : Iron (II) ions catalyze the oxidation of luminol. The intensity of the resulting chemiluminescence has been shown to increase linearly with iron (ii) concentration from 10^-10 to 10^-8 M.
What is the maximum amount of o2 in grams : What is the maximum amount of O2 in grams that can be obtained from 2.00 x 102 g of nitroglycerin?
Sentinel-controlled repetition to allow a user : The computeShippingCharges() method should use sentinel-controlled repetition to allow a user to enter shipping data until the user has indicated that he or she is done. The total shipping charges will be computed and returned as a double value.
State concentration for isotonic solutions of other salts : An isotonic solution is described as 0.92% NaCl (g/mL). Would this also be the required concentration for isotonic solutions of other salts, such as KCl, MgCl2,
Explain why swirling or shaking a solution : In less than a 150 words, explain why swirling or shaking a solution and its drying agent hastens the drying process.
State what molarity of aqueous aluminum sulfate : What molarity of aqueous aluminum sulfate solution can be expected to show the same conductivity as 0.030 M Na2SO4 at 36,000 units?
Values that occur just once : This list has some values that occur just once (1, 3, 4, 11, 13, 18), some values that occur twice (9, 16), some values that occur three times (14, 19) and a single value that occurs four times (7). Therefore, the call of list.maxCount() should re..

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Write a program to simulate the operation of a simple robot

Write a program to simulate the operation of a simple robot . the robot moves in fourdirections :forward , right , left. the job of the robot is to move items and place it in the right slots in each station. there are 8 stations plus the pick up stat..

  Design suitable mechanism to solve graph coloring problem

Consider a graph coloring problem where we have a very large graph G = (V, E), whose vertices are to be colored using 3 distinct colors such that no adjacent node in G has the same color. Design a suitable mechanism to solve the given problem.

  Sequence of events and signals activated

Describe the sequence of events and signals activated when a 6800 device wants to exchange data with the 68000 processor.

  The strike predicate need not work

Define a predicate strike(X,Y,Z) that succeeds if and only if the list Z would be obtained if one were to remove all occurrences of element X from list Y. The strike predicate need not work well when Y is an unbound variable.

  Compare and contrast the following, in terms of cores

Compare and contrast the following, in terms of cores (or microprocessors), random access memory (RAM), disk storage, and networking capabilities. Supercomputers, Mainframe computers , Desktop, computers, Laptops, Handheld computers

  Weighted probabilities for x86 processors

Create a procedure that receives a value N between 0 to 100. When the procedure is called, there should be a probability of N/100 that it clears the Zero flag. Write a program that asks the user to enter a probability value 0 to 100.

  The arrangement of a group of variables along a grid

a two-dimensional array is nothing more than the arrangement of a group of variables along a grid. Each variable occupies a specific row and column

  Explaining geographical information systems

Considering this, explain in scholarly detail some suitable examples of geographical information systems and how they are utilized in supporting both marketing and sales.

  Cpu-best performance improvement for least amount of money

Suppose the daytime processing load consists of 60% CPU activityand 40% disk activity. Your customers are complaining that thesystem is slow. Which would you choose to yield the best performance improvement for the least amount of money?

  Finding decimal equivalent of eight bit numbers

Let the two 8-bit numbers A=01000001 and B=10000100. Provide the decimal equivalent of each number.

  Use active directory to establish security group memberships

How would you manage creation of novel user accounts in this organization? Utilizing Active Directory to establish security group memberships or manual creation and security.

  It department staffing easier-less expensive as technologies

IT department staffing should become easier and less expensive as technologies simplify and become more mainstream. Agree or disagree and why?

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd