Create a class named weatherreport

Assignment Help Basic Computer Science
Reference no: EM131396101

Create a class named WeatherReport that holds a daily weather report with data members such as dayOfMonth, highTemp, lowTemp, amountRain, and amountSnow. The constructor initializes the fields with default values: 99 for dayOfMonth, -9999 for highTemp, 9999 for lowTemp, and 0 for amountRain and amountSnow. Include a function that prompts the user and sets values for each field so that you can override the default values. Instantiate 30 WeatherReport objects and, in a loop, prompt the user for a month's data.

At the end of the month, a month-end WeatherReport object is created. Initialize the object with default values; then use a friend function to store the high temperature, low temperature, and rain and snow totals for the month in the object. The friend function takes two WeatherReport objects-the summary object and one day's object-and it returns an updated summary object. If the day's high temperature is higher than the summary object's high, then replace the summary high. If the day's low temperature is lower than the summary object's low, then replace the summary low. Accumulate rain and snow in the summary object. Write a main()function that creates a month-end weather report from the 30 daily reports. Save the file as WeatherReport.cpp.

Reference no: EM131396101

Questions Cloud

Exchange rate effects on industry : Using shifts in supply and demand curves, describe how a change in the exchange rate affected your industry. Label the axes, and state the geographic, product, and time dimensions of the demand and supply curves you are drawing.
How given results help in deciding about 12 disputed papers : In each passage they counted the frequency of certain words. The results for the word by are shown in the table. Is by used with significantly different frequency by the two writers? Explain how these results help in deciding about the 12 disputed..
Predict the impact on profitability in both situations : Compare the primary costs involved in cleaning up the water immediately (and thus confessing)versus hiding your culpability now and possibly paying more in the future. Predict the impact on profitability in both situations.
Derive the correlations : Derive the correlations between P* and Y, and Q* and Y. Discuss their signs. (Quantitative methods in Economics)
Create a class named weatherreport : Accumulate rain and snow in the summary object. Write a main()function that creates a month-end weather report from the 30 daily reports. Save the file as WeatherReport.cpp.
Derive the implicit function rule : Derive the implicit function rule. (Quantitative methods in Economics)
Is given problem one of independence or of goodness of fit : Is by used with significantly different frequency by the two writers? Explain how these results help in deciding about the 12 disputed papers.
Create a friend function that displays a customer number : Create a friend function that displays a customer number and the customer's city, state, and zip code. Write a brief main()function to test the classes and friend function. Save the file as Customer.cpp
Started a printing business in duluth : Penelope has recently started a printing business in Duluth. She had to pay a fee to obtain a trade license from the Minnesota government and took a loan from the local bank to purchase inkjet printers, laser printers, and screen printers.

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Identifies the cost of computer

identifies the cost of computer components to configure a computer system (including all peripheral devices where needed) for use in one of the following four situations:

  Input devices

Compare how the gestures data is generated and represented for interpretation in each of the following input devices. In your comparison, consider the data formats (radio waves, electrical signal, sound, etc.), device drivers, operating systems suppo..

  Cores on computer systems

Assignment : Cores on Computer Systems:  Differentiate between multiprocessor systems and many-core systems in terms of power efficiency, cost benefit analysis, instructions processing efficiency, and packaging form factors.

  Prepare an annual budget in an excel spreadsheet

Prepare working solutions in Excel that will manage the annual budget

  Write a research paper in relation to a software design

Research paper in relation to a Software Design related topic

  Describe the forest, domain, ou, and trust configuration

Describe the forest, domain, OU, and trust configuration for Bluesky. Include a chart or diagram of the current configuration. Currently Bluesky has a single domain and default OU structure.

  Construct a truth table for the boolean expression

Construct a truth table for the Boolean expressions ABC + A'B'C' ABC + AB'C' + A'B'C' A(BC' + B'C)

  Evaluate the cost of materials

Evaluate the cost of materials

  The marie simulator

Depending on how comfortable you are with using the MARIE simulator after reading

  What is the main advantage of using master pages

What is the main advantage of using master pages. Explain the purpose and advantage of using styles.

  Describe the three fundamental models of distributed systems

Explain the two approaches to packet delivery by the network layer in Distributed Systems. Describe the three fundamental models of Distributed Systems

  Distinguish between caching and buffering

Distinguish between caching and buffering The failure model defines the ways in which failure may occur in order to provide an understanding of the effects of failure. Give one type of failure with a brief description of the failure

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