Question: Write a C + + program with a source file named FindWeight.cpp . Your program will ask the user to enter the mass of an
Write a C program with a source file named FindWeight.cpp Your program will ask the user to enter the mass of an object in kilograms and then display the weight of the object on the Earth, on the Moon, on Mercury, and on Venus in Newtons. The program will also display a message indicating that the object is heavy is if weighs over Newtons on Earth. The program will display a message indicating that the object is light if it weighs less than Newtons on Earth.
To calculate the weight of the object in Newtons, multiply its mass in kilograms by the acceleration due to gravity. For Earth use msect for the Moon use msec for Mercury use msec and for Venus us msect for your acceleration. Define named constants doubles for each of these.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
