Advertisement
Guest User

test

a guest
Jan 18th, 2017
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.57 KB | None | 0 0
  1. // ConsoleApplication17.cpp : Defines the entry point for the console application.
  2. //
  3.  
  4. #include "stdafx.h"
  5. #include <iostream>
  6. #include <string>
  7. #include <cmath>
  8. using namespace std;
  9.  
  10. int main()
  11. {
  12.     double weight;
  13.     double calcweight = (weight*.45);
  14.     double height;
  15.     double height2 = (height*.025);
  16.     double calcheight = pow(height2, 2);
  17.     double bmi = (calcweight / calcheight);
  18.     cout << "enter in weight " << endl;
  19.     cin >> weight;
  20.     cout << "enter in height" << "\n";
  21.     cin >> height;
  22.     cout << "your bmi is " << bmi << "." << endl;
  23.  
  24.     system("pause");
  25.     return 0;
  26. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement