Question: C++ program please help thank you so much !! Here are some helpful formulas for this program. centimeters meters x 100.0 kilograms= grams volume length
Here are some helpful formulas for this program. centimeters meters x 100.0 kilograms= grams volume length x width x height mass- volume x density 1000.0 The program must do the following: .Prompt the user for the length, width, and height in meters and input them into 3 double variables. Prompt the user for the name of the cube' s material and input it into a string variable. Prompt the user for the density of the material in g/cm and input it into a double variable. Calculate the volume of the cube in cm. Note that the input is in meters and will need to be converted. . Calculate the mass of the cube in kg . Output the name of the material, volume (cm2), density(g/cm'), and mass (kg) of the cube with labels in the following format: Name Material Name Here Vol.(cm^ 3) Volume Dens. (g/cm 3) Density Mass (kg) Mass The output must be presented in 4 columns, each 20 characters wide. mass will be right justified. the mass must be presented with 4 digits of precision. The name column must be left justified. Volume, density, and The volume and density values will use 1 digit of precision and The following concepts from the lecture will be useful for this lab: setw(int) setprecision (int) .fixed left and right the string datatype .cin.ignore () . getline (istream, string) .The
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
