Purchase Solution

C++ Program

Not what you're looking for?

Ask Custom Question

Write an interactive C++ program whose input is a series of 12 temperatures from the user.

It should write out on file "tempdate.dat" each temperature as well as the differences between the current temperature and the one preceding it, and the average of input temperatures. Since there is no preceding temperature for the first input, you can either not output the difference for the first temperature that is input, or consider this difference as 0.

At the end of the program, display the average temperature for the user via "cout".

Please do not use any of "if", "for" or "while" statements in the solution.

Purchase this Solution

Solution Summary

The expert examines an interactive C++ program to read in temperatures.

Purchase this Solution

Free BrainMass Quizzes
The Moon

Test your knowledge of moon phases and movement.

Introduction to Nanotechnology/Nanomaterials

This quiz is for any area of science. Test yourself to see what knowledge of nanotechnology you have. This content will also make you familiar with basic concepts of nanotechnology.

Classical Mechanics

This quiz is designed to test and improve your knowledge on Classical Mechanics.

Intro to the Physics Waves

Some short-answer questions involving the basic vocabulary of string, sound, and water waves.

Variables in Science Experiments

How well do you understand variables? Test your knowledge of independent (manipulated), dependent (responding), and controlled variables with this 10 question quiz.