area of triangle

/* calculate the area of triangle */

#include
#include

void main()

{
float t,b,h;
clrscr();
printf("enter value for b:");
scanf("%f",&b);
printf("enter value for h:");
scanf("%f",&h);
t=(float)0.5*b*h;
printf("%f",t);
getch();
}

1 comments:

Unknown said...

What was the out put?

Post a Comment