Write a C program to Calculate Area of a Right Angled Triangle
Program:-
#include <stdio.h>
#include <math.h>
#include <conio.h>
int main()
{
float p,b area;
printf("Enter the length of base and height of triangle");
scanf("%f %f ", &b, &h,);
area = (b*p)/2;
printf("Area of triangle : %f", area);
getch();
return 0;
}
Output :-
Input:
Enter the three sides of the Triangle
b=?
p=?
Output:-
...
0 comments:
Post a Comment