// BlankConsoleLab.cpp : This file contains the 'main' function. Program execution begins and ends there. // #include using namespace std; using std::cout; using std::cin; using std::endl; int main() { int length; float width; float area_cm; float area_m; float ratio; int grav = 9.81; float mass; int weight = 135; int grav_pull; int masskg; do { cout << "Enter Length of kite in cm: "; cin >> length; cout << "Enter Width of kite in cm: "; cin >> width; cout << "Length = " << length << " cm" << endl; cout << "Width = " << width << " cm" << endl; } while ((length < 1 || length > 400) || (width < 1 || width > 400)); // area calculation area_cm = (length * width) / 2; // unit conversion area_m = area_cm / 10000; cout << "Kite area: " << area_m << " square meters" << endl; // aspect ratio ratio = width / length; if (ratio > 1) cout << "WARNING! A lower aspect ratio would provide more stability" << endl; // mass calculation mass = (area_m * weight) / grav; cout << "Total mass of the kite is: " << mass << " Grams" << endl; //force applied to the kite converted to Newtons masskg = mass / 1000; grav_pull = mass * grav; cout << "Gravitational pull applied to the kite is: " << grav_pull << " Newtons" << endl; return 0; }