The Amalgamated Collective for Ubiquity (ACU) provides the following definitions.
A triangle is a geometric figure with three straight sides.
An isosceles triangle is any triangle with two sides of the same length.
An equilateral triangle is any triangle with all sides of the same length.
A scalene triangle is any triangle with all sides of different lengths.
A right triangle is any triangle which contains a 90-degree angle.
An acute triangle is any triangle with all angles less than 90 degrees.
An obtuse triangle is any triangle with one angle greater than 90 degrees.
An obtuse isosceles triangle is both an isosceles triangle and an obtuse triangle.
A right isosceles triangle is both an isosceles triangle and a right triangle.
An acute isosceles triangle is both an isosceles triangle and an acute triangle.
A right scalene triangle is both a scalene triangle and a right triangle.
An acute scalene triangle is both a scalene triangle and an acute triangle.
An obtuse scalene triangle is both a scalene triangle and an obtuse triangle.
Determine the most specific description for a triangle given its specification.
InputThe first line will contain the number of data sets to process. Each data set contains 6 integer numbers: A, M, B, N, C, and O; each separated by one or more spaces. A, B and C are the ordered lengths of the sides of a triangle; similarly, M, N and O are the ordered interior angles of the same triangle. The angle M is formed by the sides of length A and B. |
OutputEach data set should produce one line of output containing the most specific description possible for the triangle. | |
Sample input:
4 3 90 4 37 5 53 10 60 10 60 10 60 11 50 10 60 10 70 20 110 10 60 30 10 |
Sample output:
right scalene triangle equilateral triangle acute isosceles triangle obtuse scalene triangle |