I need help with this homework assignement. Write a C++ program that uses a fixe
ID: 3676770 • Letter: I
Question
I need help with this homework assignement.
Write a C++ program that uses a fixed-count loop of four. For each pass through the loop, enter a fluid’s viscosity and density from the following chart. Your program should then determine the kinematic viscosity for each fluid, using the following formula (see the Technical Note in Section 5.2 for a description of density and viscosity): Kinematic viscosity = viscosity / density
Fluid Viscosity at 40 C= 77F Denisty Kinemtic Visocity Gas .4466 * pow(10, .3) .7186 * pow(10,3) Fuel Oil 2.9922 * pow(10, -3) .8496 * pow(10, 3) Lub Oil 87.0736 * pow(10, -3) .8865 * pow(10, 3) Water .8975 * pow(10, -3) .9973 * pow( 10,3)Explanation / Answer
#include <iostream>
using namespace std;
int main()
{
int vi,den,n;
double kinematic;
cout << "Please enter viscosity";
cin >> vi;
cout << "Please enter density";
cin >> den;
for(int i=0, i<n; i++){
kinematic = vi/den;
}
cout << "The kinematic viscosity is " << kinematic << endl;
return 0;
}