diff options
Diffstat (limited to 'BlankConsoleLab/BlankConsoleLab.cpp')
| -rw-r--r-- | BlankConsoleLab/BlankConsoleLab.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/BlankConsoleLab/BlankConsoleLab.cpp b/BlankConsoleLab/BlankConsoleLab.cpp index 22fb44e..0ce3b2c 100644 --- a/BlankConsoleLab/BlankConsoleLab.cpp +++ b/BlankConsoleLab/BlankConsoleLab.cpp @@ -20,7 +20,7 @@ using std::endl; int main() { //seting up variables - float length, width, area, aspectRatio; + float length, width, area, aspectRatio, mass, gPull; bool dimensions = false; //keeps on looping until the user inputs a length and a width between 1 and 400 @@ -59,8 +59,12 @@ int main() cout << "NOTE: A lower aspect ratio (below 1) would provide more stability"; } + //calculating mass of kite + mass = (area * 135) / 1000; + //calculating gravitational pull + gPull = mass * 9.8; - + cout << "Your kite weighs " << gPull << " kg." } |