Wednesday, August 3, 2011
Write a program to compute the values of volume for a sphere and a cube based on input values from the user.?
Write a program to compute the values of volume for a sphere and a cube based on input values from the user and using the above formulae. For the spherical calculation only one value need be entered but for the cube there are 3 specific values, each with a relationship that also defines its physical orientation (height, width or depth, and length).Your program should have a simple descriptive title such as “RJA Computations”, some simple instructions for the user, input for the necessary values and display of the resulting values. For both input of values and the display of final results there should be enough information to allow any user to understand what the program requires and what it has accomplished. Use appropriate IO Manipulators to format your messages, input values and final results.The program need only make one pass of operation to input values and compute the results. However, the program should pause before returning control to the operating system.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment