Answer to Question #101264 in C++ for Madhur

Question #101264
WAP to calculate the value of S where
S=U*T+0.5*G*T*T
1
Expert's answer
2020-01-15T09:41:31-0500
#include <iostream>
using namespace std;

int main()
{
    cout << "U = ";
    double U;
    cin >> U;

    cout << "G = ";
    double G;
    cin >> G;

    cout << "T = ";
    double T;
    cin >> T;

    double S = U*T+0.5*G*T*T;
    cout << "S = " << S << endl;
    return 0;
}

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