write a c program to calculate the area of triangle
Answers
Answered by
6
C Program to find Area Of a Triangle using base and height
#include<stdio.h>
int main()
{
float base, height, area;
printf("\n Please Enter the Base of a Triangle : ");
scanf("%f", &base);
printf("\n Please Enter the Height of a Triangle : ");
scanf("%f", &height);
area = (base * height) / 2;
printf("\n The Area of a Triangle using Base and Height = %.2f\n", area);
return 0;
}
Attachments:
![](https://hi-static.z-dn.net/files/d21/f0225eb53fb7917b95d236238c858817.png)
Similar questions