This project has moved and is read-only. For the latest updates, please go here.

 

Click here to open this program directly in Turbo C++

 

#include <stdio.h>
#include <conio.h>
#include <math.h>
void main()
{
int s, a, b, c, area;
clrscr();
printf("Enter the values of a,b and c\n");
scanf ("%d %d %d", &a, &b, &c);
/* compute s*/
s = (a + b + c) / 2;
area = sqrt ( s * (s-a) * (s-b) * (s-c));
printf ("Area of a triangale = %d\n", area);
getch();
}

/*-----------------------------
Output
Enter the values of a,b and c
3
4
5
Area of a triangale = 6
------------------------------*/

Last edited Aug 31 at 6:58 PM by vineetchoudhary, version 5