Question: The area of an arbitrary triangle can be computed using the formula where a , b , and c are the lengths of the sides,

The area of an arbitrary triangle can be computed using the formula
where a, b, and c are the lengths of the sides, and s is the semiperimerter.
Write a void function that uses three parameters: two reference parameters and one value parameter. All three parameters provide the lengths of the edges, but the two reference parameters can return the area and perimeter (not the semiperimeter). Make your function robust. Note that not all combinations of a, b, and c produce a triangle. Your function should produce correct results for legal data and reasonable results for illegal combinations. Then output the area and perimeter.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!