diff options
| author | Matthew Taeza <[email protected]> | 2022-10-16 12:11:50 -0700 |
|---|---|---|
| committer | Matthew Taeza <[email protected]> | 2022-10-16 12:11:50 -0700 |
| commit | 54a2f610614eb77376a3b45f1298e923714766af (patch) | |
| tree | eabc8ecfbaa6832f48e3da606143b00ba73cdbf0 | |
| parent | Setting up GitHub Classroom Feedback (diff) | |
| download | cst116-lab1-matthewtaeza-54a2f610614eb77376a3b45f1298e923714766af.tar.xz cst116-lab1-matthewtaeza-54a2f610614eb77376a3b45f1298e923714766af.zip | |
First Commit
| -rw-r--r-- | BlankConsoleLab/BlankConsoleLab.cpp | 29 | ||||
| -rw-r--r-- | BlankConsoleLab/BlankConsoleLab.vcxproj | 8 |
2 files changed, 32 insertions, 5 deletions
diff --git a/BlankConsoleLab/BlankConsoleLab.cpp b/BlankConsoleLab/BlankConsoleLab.cpp index ed5f807..1f4452f 100644 --- a/BlankConsoleLab/BlankConsoleLab.cpp +++ b/BlankConsoleLab/BlankConsoleLab.cpp @@ -11,6 +11,33 @@ using std::endl; int main() { - cout << "Hello World!\n"; + //Variables + float WidthK; //Width of Kite + float LengthK; //Length of Kite + float CMarea; //Centimeters Area + float Marea; //Meters Area + float AR; //Aspect Ratio + + cout << "input width of the kite ->> "; + cin >> WidthK; + + cout << "input length of the kite ->> "; + cin >> LengthK; + + CMarea = (WidthK * LengthK) / 2; + + Marea = CMarea / 10000; + + AR = WidthK / LengthK; + + cout << "The area of the kite in centimeters = " << CMarea << endl; + cout << "The area of the kite in meters = " << Marea << endl; + cout << "The aspect ratio of the kite = " << AR << endl; + + if (AR >= 1) + { + cout << "A lower aspect ratio would provide more stability"; + } + } diff --git a/BlankConsoleLab/BlankConsoleLab.vcxproj b/BlankConsoleLab/BlankConsoleLab.vcxproj index db2e734..d2e3ee2 100644 --- a/BlankConsoleLab/BlankConsoleLab.vcxproj +++ b/BlankConsoleLab/BlankConsoleLab.vcxproj @@ -29,26 +29,26 @@ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> <ConfigurationType>Application</ConfigurationType> <UseDebugLibraries>true</UseDebugLibraries> - <PlatformToolset>v142</PlatformToolset> + <PlatformToolset>v143</PlatformToolset> <CharacterSet>Unicode</CharacterSet> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> <ConfigurationType>Application</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> - <PlatformToolset>v142</PlatformToolset> + <PlatformToolset>v143</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration"> <ConfigurationType>Application</ConfigurationType> <UseDebugLibraries>true</UseDebugLibraries> - <PlatformToolset>v142</PlatformToolset> + <PlatformToolset>v143</PlatformToolset> <CharacterSet>Unicode</CharacterSet> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration"> <ConfigurationType>Application</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> - <PlatformToolset>v142</PlatformToolset> + <PlatformToolset>v143</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> </PropertyGroup> |