subject
Engineering, 30.11.2019 04:31 hfleysher

Create a class, airtravelcost, that has the following characteristics: •attributes of departure/arrival date (stringin the form mmdd), departure/arrival time (stringin the form hhmm), destination, travelfare, and hotelcost(cost per night). •a constructor that accepts and updates all the attributes•a normal accessor for destination•durationcan be calculated. use the gregoriancalendar class. ocreate two gregoriancalendar objects, one for each of the departure and arrival dates and times. ouse the gettimeinmillismethod to get a date/time in milliseconds since a standard date & time. osubtract the two values (for the departure and arrival date/time) to yield duration in milliseconds. odivide the result by 60,000to get minutes and divide again by 60to get hours, etc. •calculate the lodging (hotel) cost by dividing the durationby 24hours and use the number of whole days only (no partial days). multiply the number of days by the hotel cost per night. •the total cost can be calculated as travelfare + getlodgingcost() + agent_fee•a tostringmethod returns a string formatted by string. format()who’s output looks like "air travel to destinationwill take durationand cost totalcost"

ansver
Answers: 3

Other questions on the subject: Engineering

image
Engineering, 03.07.2019 14:10, BardiFan
Amass of m 1.5 kg of steam is contained in a closed rigid container. initially the pressure and temperature of the steam are: p 1.5 mpa and t 240°c (superheated state), respectively. then the temperature drops to t2= 100°c as the result of heat transfer to the surroundings. determine: a) quality of the steam at the end of the process, b) heat transfer with the surroundings. for: p1.5 mpa and t 240°c: enthalpy of superheated vapour is 2900 kj/kg, specific volume of superheated vapour is 0. 1483 m/kg, while for t 100°c: enthalpy of saturated liquid water is 419kj/kg, specific volume of saturated liquid water is 0.001043m/kg, enthalpy of saturated vapour is 2676 kj/kg, specific volume of saturated vapour is 1.672 m/kg and pressure is 0.1 mpa.
Answers: 3
image
Engineering, 04.07.2019 18:10, lillygrl100
For the closed feedwater heater below, feedwater enters state 3 at a pressure of 2000 psia and temperature of 420 °f at a rate of ix10 ibhr. the feedwat extracted steam enters state 1 at a pressure of 1000 psia and enthalpy of 1500 btu/lbm. the extracted er leaves at an enthalpy of 528.7 btu/lbm steam leaves as a saturated liquid. (16) a) determine the mass flow rate of the extraction steam used to heat the feedwater (10) b) determine the terminal temperature difference of the closed feedwater heater
Answers: 3
image
Engineering, 04.07.2019 18:10, leomessifanboy678
The filament of an incandescent lamp has a temperature of 2000k. calculate the fraction of radiation emitted in the visible light band if the filament is approximated as blackbody
Answers: 2
image
Engineering, 04.07.2019 18:10, aliopqwas
Condition monitoring is a major component of. (clo4) a)- predictive maintenance. b)-preventive maintenance c)-proactive maintenance d)-reactive maintenance.
Answers: 1
You know the right answer?
Create a class, airtravelcost, that has the following characteristics: •attributes of departure/arri...

Questions in other subjects: