blob: 1f611978f0057e2ec4fc73c40013af8cf716e8ba (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
// 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()
{
float width = 0;
float length = 0;
float area;
float aspect_ratio;
cout << "What is the width of the kite in centimeters: ";
cin >> width;
cout << "What is the length of the kite in centimeters: ";
cin >> length;
cout << "The width is " << width << " centimeters and the length is "
<< length << " centimeters." << endl;
area = (length * width) / 2;
cout << "The area of the kite is " << area / 10000 << " square meters." << endl;
aspect_ratio = width / length;
if (aspect_ratio >= 1)
cout << "WARNING! A lower aspect ratio will provide more stability.";
else (aspect_ratio < 1);
cout << "Good aspect ratio.";
}
|