Q15 If the lengths of the sides of a triangle are denoted by a, b, c, then area of triangle is given by area = √(S(S-a)(S-b)(S-c)) Where, S = (a+b+c)/2. Write a function to calculate the area of the triangle.

Write a c function to calculate the area of the triangle

Program: 136

If the lengths of the sides of a triangle are denoted by a, b, c, then area of triangle is given by


area = √(S(S-a)(S-b)(S-c))
Where, S = (a+b+c)/2.


Write a c function to calculate the area of the triangle.

Output:

Enter a: 3
Enter b: 2
Enter c: 4
Area of Triangle: 2.904737
Lokesh Kumar: Being EASTER SCIENCE's founder, Lokesh Kumar wants to share his knowledge and ideas. His motive is "We assist you to choose the best", He believes in different thinking.
Related Post
Leave a Comment

This website uses cookies.