From 09d8e7a1f807e57651c6707049bf21ccbd49f424 Mon Sep 17 00:00:00 2001 From: CEOofOogaBooga Date: Tue, 18 Oct 2022 19:27:36 -0700 Subject: Area step --- BlankConsoleLab/BlankConsoleLab.cpp | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) (limited to 'BlankConsoleLab/BlankConsoleLab.cpp') diff --git a/BlankConsoleLab/BlankConsoleLab.cpp b/BlankConsoleLab/BlankConsoleLab.cpp index ed5f807..e63706e 100644 --- a/BlankConsoleLab/BlankConsoleLab.cpp +++ b/BlankConsoleLab/BlankConsoleLab.cpp @@ -1,16 +1,25 @@ // BlankConsoleLab.cpp : This file contains the 'main' function. Program execution begins and ends there. // - +/* +Thomas Trinh +CST116 +Lab 1 Kite Dimensions +*/ #include using namespace std; -using std::cout; -using std::cin; -using std::endl; - +int width = 0; +int length = 0; +float area = 0; int main() { - cout << "Hello World!\n"; + cout << "Enter width in cm: "; + cin >> width; + cout << "Enter length in cm: "; + cin >> length; + area = ((length * width)/2)/10000; + cout << "Area in square meters: " << area; + } -- cgit v1.2.3