Calculate and display running total of yesterday receipts

Assignment Help Basic Computer Science
Reference no: EM13219742

A parking garage charges a $2.00 minimum fee to park for up to three hours. The garage charges an additional $0.50 per hour for each hour or part thereof in excess of three hours. The maximum charge for any given 24-hour period is $10.00. Assume that no car parks for longer than 24 hours at a time. Write an application that calculates and displays the parking charges for each customer who parked in the garage yesterday. You should enter the hours parked for each customer. The program should display the charge for the current customer and should calculate and display the running total of yesterday's receipts. The program should use the method calculate-Charges to determine the charge for each customer. Your output should appear as follows: Enter number of hours (a negative to quit): 2 Current charge: $2.00, Total receipts: $2.00 Enter number of hours (a negative to quit): 10 Current charge: $5.50, Total receipts: $7.50 Enter number of hours (a negative to quit): -1

Reference no: EM13219742

Questions Cloud

Write a program that prompts the user : Java: Write a program that prompts the user to enter the number of students and each student's name and score, than display the name of the student with the highest score.
What is a corporate strategy : What line of work is the company and what products or services does the company provide and From a strategy perspective, what is a corporate strategy
What drives excessive technology investments in each model : Explain how either the Newhouse model or the Physician Workshop model could explain why hospitals might inefficiently over-invest in expensive, new technologies. What drives excessive technology investments in each model
Write the definition of a class counter containing : Write the definition of a class Counter containing: An instance variable named counter of type int An instance variable named limit of type int . A constructor that takes two int arguments and assigns the first one to counter and the s..
Calculate and display running total of yesterday receipts : calculate and display the running total of yesterday's receipts. The program should use the method calculate-Charges to determine the charge for each customer.
Compute the maximum safe diameter w of the port : The vessel will contain gases at pressures up to 210.0 MPa. The student's design calls for an observation port on the side of the vessel (see diagram below). The bolts that hold the cover of this port onto the vessel can safely withstand a force o..
Write a program for line clliping : Write a program for line clliping. Take co-ordinate of 2 point as input and also take 4 co-ordinates of window. It should clip the line outside the window. Dont use built in function like line or rectangle to draw line or rectangle.Use dda line al..
Determine what is the amount of excess reserrves : This bank can safely expand its loans by what amount c.by expanding its loans by this amount in part (b), its checkable deposits would expand to what amount (if all loans were made to ch3ecking account customers)
What stable monetary policy has been highly erratic : The velocity of M1 money has moved erratically in the past several years because Answer of low and stable rates of inflation of regulatory changes allowing banks to pay interest on checkable deposits interest rates have been stable monetary policy..

Reviews

Write a Review

Basic Computer Science Questions & Answers

  What is the average length of the search for worst-fit

another placement algorithm for dynamic partitioning is referred to as worst-fit. In this case, the largest free block of memory is used for bringing in process. Discuss the pros and cons of this method compared to first-, next-, and best fit. Wha..

  The tblmaginfo table contains three fields

The tblMagInfo table contains three fields. The Code and Cost fields are numeric. The Magazine field contains text. The dataset's name is MagsDataSet.

  Drivers for digital dashboards found in automobiles

Believe or not digital dashboards can be found in automobiles. In fact, Mossberg (2010) wrote article titled, "Ford Drives Digital Dashboards to Next Level. Are drivers ready for this kind of technology?

  Explain how the web user interfaces help donors

Explain how the Web user interfaces help donors to make decisions and relate the emotional thread demonstrated in the case study to the emotional design model as discussed in Chapter 5 of the textbook.

  Excavated material to the structural fill location

How many dump truck loads, given a dump truck with 18 LCY capacity, will be required for hauling the excavated material to the structural fill location?

  Consider a 2-dimensional mesh

Consider a 2-dimensional mesh with n^2 nodes. The shortest distance that a message travels in the mesh is 1 link; the longest distance is 2(n-1) link

  Prove by contradiction that if n is a perfect square

Let n > 1 be an integer. Prove by contradiction that if n is a perfect square, then n + 3 cannot be a perfect square.

  Minimum number of edits required to convert string

Given two strings of size m, n and set of operations replace (R), insert (I) and delete (D) all at equal cost. Find minimum number of edits (operations) required to convert one string into another.

  Which of the following command removes a job at the at queue

Which of the following command removes a job at the at queue? (Select two. Each answer is an independent solution) a. atq b. atrm c. at -d d. at -f e. at -l

  Incorporate this method into an application

Incorporate this method into an application that inputs a series of pairs of integers (one pair at a time) and determines whether the second value in each pair is a multiple of the first

  Write a program to prompt the user to enter a postfix expres

Write a program to prompt the user to enter a postfix expression. When the user presses enter, the stack based method for constructing expression trees will be executed

  Determine minimum number of pieces for location of centroid

Determine the minimum number of pieces which can be used in determining location of the centroid? For finiding the centroid of area, two square segments are considered; square ABCD and square DEFG.

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