summaryrefslogtreecommitdiff
path: root/BlankConsoleLab/BlankConsoleLab.cpp
diff options
context:
space:
mode:
authorNathanturcas <[email protected]>2022-10-23 16:24:03 -0700
committerNathanturcas <[email protected]>2022-10-23 16:24:03 -0700
commit7beacce7ba95271c023012663b3af822ed1400db (patch)
treee8fc913e4709e997397b5231e1febe303b2d1666 /BlankConsoleLab/BlankConsoleLab.cpp
parentcommit 3 (diff)
downloadcst116-lab1-nathanturcas-master.tar.xz
cst116-lab1-nathanturcas-master.zip
commit 4HEADmaster
Diffstat (limited to 'BlankConsoleLab/BlankConsoleLab.cpp')
-rw-r--r--BlankConsoleLab/BlankConsoleLab.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/BlankConsoleLab/BlankConsoleLab.cpp b/BlankConsoleLab/BlankConsoleLab.cpp
index 3e4a160..f045f29 100644
--- a/BlankConsoleLab/BlankConsoleLab.cpp
+++ b/BlankConsoleLab/BlankConsoleLab.cpp
@@ -8,10 +8,11 @@ using namespace std;
using std::cout;
using std::cin;
using std::endl;
-
+
int main()
{
- float width, length, area, ratio;
+ float width, length, area, ratio, gravitational ;
+ const int mass = 135;
cout << "Enter width (cm) : ";
cin >> width;
@@ -45,8 +46,10 @@ int main()
cout << "ratio: ";
cout << ratio << endl;
if (ratio >= 1)
- cout << "a lower aspect ratio would provide more stability";
-
+ cout << "a lower aspect ratio would provide more stability" << endl;
+ gravitational = mass * area;
+ cout << "gravitational: ";
+ cout << gravitational << endl;
}