summaryrefslogtreecommitdiff
path: root/BlankConsoleLab/BlankConsoleLab.cpp
diff options
context:
space:
mode:
authorAndrei F <[email protected]>2022-10-19 21:48:06 -0700
committerAndrei F <[email protected]>2022-10-19 21:48:06 -0700
commitf02fedd7452c76623ada9b8dd3d18d5d04329267 (patch)
tree58245a6cd9beb477bdde843ad3b4292c16050ea5 /BlankConsoleLab/BlankConsoleLab.cpp
parentFinished part 1 (diff)
downloadcst116-lab1-florea-f02fedd7452c76623ada9b8dd3d18d5d04329267.tar.xz
cst116-lab1-florea-f02fedd7452c76623ada9b8dd3d18d5d04329267.zip
Correctly named files
Diffstat (limited to 'BlankConsoleLab/BlankConsoleLab.cpp')
-rw-r--r--BlankConsoleLab/BlankConsoleLab.cpp53
1 files changed, 0 insertions, 53 deletions
diff --git a/BlankConsoleLab/BlankConsoleLab.cpp b/BlankConsoleLab/BlankConsoleLab.cpp
deleted file mode 100644
index 29fa885..0000000
--- a/BlankConsoleLab/BlankConsoleLab.cpp
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Andrei Florea - CST 116 - Lab 1 (Part 1 and Part 2) - Learning input, output, if statements, loops, simple
- * calculations
- *
- * The purpose of this program is to take input regarding kite specifications and output
- * if the kite is efficient at flying or if it is able to fly.
- *
- */
-
-#include <iostream>
-
-using namespace std;
-
-using std::cout;
-using std::cin;
-using std::endl;
-
-int main()
-{
- float width = 0;
- float length = 0;
- float area, ratio;
-
- while(!(width <= 400 && width >= 1 && length <= 400 && length >= 1)) {
- cout << "Please only enter WIDTH and LENGTH between 1 - 400" << endl;
-
- cout << "Please enter the WIDTH of your kite in centimeters (decimals are OK): ";
- cin >> width;
-
- cout << "Please enter the LENGTH of your kite in centimeters (decimals are OK): ";
- cin >> length;
- }
- cout << "Width: " << width << " CM" <<" | Length: " << length << " CM" << endl;
-
- area = (width * length) / 2;
- area /= 10000;
-
-
- cout << "Area (in square meters): " << area << " M^2" << endl;
-
- const float mass = 135 * area;
- cout << "If your kite is using a medium weight fabric, it is calculated to weigh: " << mass << " grams/meter^2"
- << endl;
-
-
- ratio = width / length;
- if(ratio >= 1){
- cout << "Warning: a lower aspect ratio would provide more stability." << endl;
- cout << "Current aspect ratio: " << ratio << " (width / length)"<< endl;
- }
-
-}
-