Answer to Question #260308 in C++ for Sri

Question #260308

Make a C++ program the application of C++, and write the program at journal's paper, which find about the value of mechanical energy, with the following conditions: some people throw (by vertical) 20 mangoes with the weight of each mango is 100 gram. If the mangoes are thrown together by them. Then what is the value of the mechanical energy that occurs in that situation. With height is 10 meters and the acceleration is 1,25 m/s²in 4 second. (The acceleration due to gravity is 10 meters per second square). And as we know to find the value of the mechanical energy of an object is to first find the potential energy them the kinetic energy and then add both, next, it is the value of its mechanical energy.

1
Expert's answer
2021-11-02T17:35:28-0400


SOLUTION TO THE ABOVE QUESTION


#include <iostream>
using namespace std;


int main()
{
   //lets calculate the potential energy
   //Potential energy is given by (P.E = mgh 
   double mass = (0.1);
   //SI units meters per square second 
   double gravity = 10;
   
   //Si units metres
   double height = 10;
   
   double potential_energy = (mass*gravity*height);


   //kinetic energy K>E =  ½ mv2;
    // units metres per square second
   double velocity = 1.25;
   double kinetic_energy = (0.5)*(velocity*velocity);
   
   //Mechanical energy is given by the sum of potential energy and kinetic energy
   //ME=KE+PE
   //SI units joules
    double mechanical_energy = potential_energy + kinetic_energy;
   //Now we have M.E for one object lets find for 20 objects
   double M_E_for_20_objects = mechanical_energy*20;
   
   //print the mechanical energy
   cout<<"\n\nThe value of mechanical energy = "<<M_E_for_20_objects<<" joules"<<endl;
}



SAMPLE PROGRAM OUTPUT




Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS