Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem.Write a program exploring how the Earths climate has changed over the past century and projecting what future temperatures might be like. You are going

Problem.Write a program exploring how the Earths climate has changed over the past century and projecting what future temperatures might be like. You are going to explore the change in sea levels and the change in air temperature. The worlds oceans have risen 1.8 mm over the past century. Forecasts indicate the rate will increase to 3.1 mm/year for the foreseeable future. In addition, the mean July air temperature was measured for the following cities for last year: New York City: 85 F, Denver: 88 F, Phoenix: 106 F, Sacramento: 92 F. Reports suggest these temperatures will increase by 0.13 F for each subsequent year into the forseeable future. Note: my sample data shown in this assignment may differ from this.Requirements.Store the results of all computations.Include your specication comments above the main portion of your code where you implement the specication. No credit if this is missing!Use white-space and comments to make your code more readable.Use function prototypes for all functions.Do not use c (.h) style libraries. Use C++ libraries instead.Your program must compile in C++ on Ubuntu.Your program must generate logically correct output.Program activities are split into logical chunks or paragraphs. Im expecting paragraphs for input, processing (if any), and output operations.If there is non integer output, force the computer to always display 3 places to the right of the decimal.Include a Source File Header, like you used in homework 1. Do not include a specification with it like you did in that assignment.Include a Commented Sample Run for this assignment like you did for homework 1. Again, do not include a specification with it.Include a ProgramGreeting for this assignment like you did for homework 1, but turn it into a function you call at the very start of main().Specications.// Specication C1- const ConversionsUse consts when converting your units of measurement. Make sure you use the appropriate ALLCAPS naming convention too. Its OK to make these global variables.// Specication C2-5 year ocean riseCompute how much the oceans will rise each year over the next 5 years. Display each years results.// Specication C3-5 year tempCompute how much the mean July temperatures will increase over the next 5 years each year. Display your results.// Specication B1- Mixed length outputDisplay your output in both inches and mm.1 mm =0.1 cm =0.03937 inches. Note: This conicts with the output in the picture, follow this. Store your conversion factor in a constant variable MM2IN. Use the appropriate style for constants.// Specication B2- Mixed temperature outputDisplay your temperatures in both C as well as F. Store the conversion factor in the constant variable F2C and make sure the style is appropriate.// Specication B3- Auto Heading FunctionCreate a function called autoHeader. This void function takes a string and displays it in all caps as a title. It then, emits a newline and displays = underlining each letter in the title. Do not send an all caps string, nd the library function which will convert to uppercase for you. You may be wondering how to automatically underline the title.// Specification A1- Ocean Rise TableCreate a table, similar to the one in homework 2, which holds the 5 year ocean rise, in both mm and inches. Display this table (wouldnt it be great if you could create a couple of functions to do this and then copy them from homework to homework?).// Specification A2- July Temp TableConstruct a table similar to the one in specification A1, include column for both celsus and fahrenheit.// Specification A3- One FunctionInclude at least one function in your program. Put this specification comment above your function prototype(s).

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Modern Database Management

Authors: Jeff Hoffer, Ramesh Venkataraman, Heikki Topi

13th Edition Global Edition

1292263350, 978-1292263359

More Books

Students also viewed these Databases questions