## Question 1

Please input the bottom length of a triangle (integer). (output)

3 ⏎ (input)

Please input the height of the triangle (integer). (output)

4 ⏎ (input)

The area of the triangle is 6.00. (output)

#include<stdio.h>

int main (void) {
int bot_len, height;
double area;

printf("Please input the bottom length of a triangle (integer).\n");
scanf("%d", &bot_len);

printf("Please input the height of the triangle (integer).\n");
scanf("%d", &height);

area = (double) bot_len * (double) height / 2.0;
printf("The area of the traingle is %.2lf.\n", area);

return 0;
}


## Question 2

172.3 ⏎ (input)

65.0 ⏎ (input)

The standard BMI is assumed to be 24.0. (output)

The difference with a standard weight is YYY kg. (output)

#include<stdio.h>

int main (void) {
double height, weight, BMI;
double height_meter, std_weight;

scanf("%lf", &height);
scanf("%lf", &weight);

height_meter = height / 100.0;

BMI = (weight) / (height_meter * height_meter);
std_weight = 24.0 * (height_meter * height_meter);

}