summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliamBishopCST116 <[email protected]>2022-10-17 12:30:57 -0700
committerGitHub <[email protected]>2022-10-17 12:30:57 -0700
commit65b564ee0fc7339487d082dafec7337c206cdb04 (patch)
tree26596695be3d3fcd0a7db38d49638a2f11f58499
parentAdd files via upload (diff)
downloadcst116-lab1-williambishopcst116-65b564ee0fc7339487d082dafec7337c206cdb04.tar.xz
cst116-lab1-williambishopcst116-65b564ee0fc7339487d082dafec7337c206cdb04.zip
Add files via upload
-rw-r--r--CST116-Lab1-Bishop-Submission9.cpp111
1 files changed, 111 insertions, 0 deletions
diff --git a/CST116-Lab1-Bishop-Submission9.cpp b/CST116-Lab1-Bishop-Submission9.cpp
new file mode 100644
index 0000000..c6d8b42
--- /dev/null
+++ b/CST116-Lab1-Bishop-Submission9.cpp
@@ -0,0 +1,111 @@
+//William Bishop
+
+// BlankConsoleLab.cpp : This file contains the 'main' function. Program execution begins and ends there.
+//
+
+#include <iostream>
+
+using namespace std;
+
+using std::cout;
+using std::cin;
+using std::endl;
+
+int main()
+{
+ int kite;
+ int horizontal_kitew;
+ int vertical_kitel;
+
+ cout << "Please enter a width of the kite" << endl;
+ cin >> horizontal_kitew
+ cout << "Your width is: " << horizontal_kitew << endl;
+ cout << "Please enter your height of the kite " << endl;
+ cin >> vertical_kitel;
+ cout << "Our width and the height is: " << horizontal_kitew << "and " << vertical_kitel << endl;
+
+ int areaofkite;
+ int areaofkite = (horizontal_kitew * vertical_kitel) / 2;
+ cout << "The area of the kite is " << areaofkite;
+ float Area_of_kiteM;
+ float Area_of_kiteM = areaofkite / 10000;
+ cout << " " << Area_of_kiteM << endl;
+ float aspectratio;
+ float aspectratio = horizontal_kitew / vertical_kitel;
+ cout << " Our aspect ratio is : " << aspectratio << endl;
+
+ if (aspectratio >= 1)
+ cout << " WARNING : A lower aspect ratio than 1 would make more stability. " << endl;
+ //Part two
+
+ int width2;
+ int length2;
+ float area2;
+
+ cout << "Please enter the width of the kite: ";
+
+ cout << " Please enter a width of the kite from 1 to 400. " << endl;
+ cin >> width2;
+ if (width2 > 0 && width2 < 401)
+ cout << "Thank you for entering. " << width2;
+ else
+ cout << "Please enter the width from 1 to 400. " << endl;
+ cin >> width2;
+
+ cout << "Please enter the length of the kite: ";
+
+ cout << " Please enter a length of the kite from 1 to 400. " << endl;
+ cin >> length2;
+ if (length2 > 0 && length2 < 401)
+ cout << "Thank you for entering. " << length2;
+ else
+ cout << "Please enter the length from 1 to 400. " << endl;
+ cin >> length2;
+ float area2 = length2 * width2;
+ cout << "The area is " << area2;
+
+ float weight;
+ float mass;
+ float height;
+ float density;
+
+ cout << "Please intput the weight of the kite. ";
+ cin >> weight;
+ cout << "Please input the height of the kite " << endl;
+ cin >> height;
+ cout << "Please input the density of the kite " << endl;
+ cin >> density;
+ cout << "Our density of the kite is " << density << "Our height of the kite is " << height;
+ float volume;
+ float volume = area2 * height;
+ float density =
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+}
+