float a, b, c, s, area;
printf(" Enter three sides of a triangle: ");
scanf("%f %f %f", &a, &b, &c);
if (a==0 || b==0 || c==0)
printf(" Value of any side should not be equal to zero ");
if (a+b<c || b+c<a || c+a<b)
printf(" Sum of two sides should not be less than third ");
s = (a + b + c) / 2;
area = sqrt(s * (s - a) * (s - b) * (s - c));
printf(" Area of triangle: %.2f", area);
Upload your original content. We will publish your material under your name on W3Professors after review.
Without your feedback, such words as Improvement, Achievement and Success have no meaning for us.
Designed and Maintained by Kanwer Technologies