answersLogoWhite

0


Best Answer

You write it exactly the same as you would write it in any other verions of C++, by taking user input to determine the three sides of your triangle. In other words, input three real numbers. What you do with those three numbers is entirely up to you, but presumably you'd want to calculate the angles of a triangle given the length of its three sides. For that you would need to use the cosine rule which states that for any triangle with angles A, B and C whose opposing sides are a, b and c respectively, cos A = (b2 + c2 - a2)/2bc and cos B = (c2 + a2 - b2)/2ca. Knowing two angles, A and B, you can easily work out that angle C must be 180 - (A + B).

User Avatar

Wiki User

10y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you write a Turbo C plus plus program that reads sides of triangle?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How do you describe triangles by the sides?

Scalene Triangle- a triangle with no congruent sides Isosceles Triangle- a triangle with two congruent sides Equilateral Triangle- a triangle with three congruent sides


What type of triangle's sides have all nine sides?

A triangle can have only three sides. No triangle can have 9 sides!


What kind of triangle has no 2 sides equal?

Scalene Triangle: a triangle with no two sides equalIsosceles Triangle: a triangle with two sides equalEquilateral Triangle: a triangle with all sides equalRight Triangle: A triangle with two 'legs' vertex creates a 90o angle.


What is a triangle with at least two congurent sides?

A triangle with two congruent sides is an isosceles triangle, and a triangle with three congruent sides is an equilateral triangle.


How is the equilateral triangle different from the isosceles triangle and scalene triangle?

They all have 3 sides but an equilateral triangle has 3 equal sides, an isosceles triangle has 2 equal sides and a scalene triangle has no equal sides.


What triangle has no congruent sides?

A scalene triangle has no congruent sides. An equilateral has all equal sides, and an isosceles triangle has two of three sides equal.


How many sides are there on a triangle?

A triangle has three sides.


Triangle with no equal sides?

A triangle with no equal sides is called a Scalene Triangle.


What triangle has 8 sides?

There is no such triangle. A triangle must have exactly 3 sides.


A triangle with no two equal sides?

A triangle with no equal sides is a scalene triangle.


How many sides does an equaladeral triangle have?

A triangle - any triangle - has 3 sides.


How can you look at the lengths of the sides of a triangle and determine what type of triangle it is by its sides?

If all 3 sides are equal: Equilateral Triangle If 2 sides are equal: Isosceles Triangle If all 3 sides are unequal/different: Scalene Triangle