Garnetao's problem
Time Limit : 3000/1000ms (Java/Other) Memory Limit : 65535/32768K (Java/Other)
Total Submission(s) : 91 Accepted Submission(s) : 47
Font: Times New Roman | Verdana | Georgia
Font Size: ← →
Problem Description
Garnetao is a member of SKYLINE(a basketball team which has gained great successes).Unluckily, he fell over himself and was injured, now he is on the bed. All of his best friends want to cheer him up, however, Garnetao will never glad until they solve his problem that he hide it deep inside his heart.What? you know, Garnetao hates triangles, he want to find the smallest circle which can cover the triangles. Don’t you want Garnetao to recover quickly? Solve it.
Input
There are multiple test cases in the input data.
Every test case contains six integer, (xi, yi), 1<=i<=3, in a two-dimensional coordinate.They indicate the three points of a triangle. It is guaranteed that there are no three points on a straight line.All of the numbers are less than 1000.
Every test case contains six integer, (xi, yi), 1<=i<=3, in a two-dimensional coordinate.They indicate the three points of a triangle. It is guaranteed that there are no three points on a straight line.All of the numbers are less than 1000.
Output
For each test case, please output x y r in one line.(x,y) is the center of the smallest circle that contain the triangle,r is the radius of the circle. Round all of the them to the nearest number with exactly two digits after the decimal point.
Sample Input
0 0 -1 0 0 -1 0 1 -1 0 1 0
Sample Output
-0.50 -0.50 0.71 0.00 0.00 1.00
Author
Source
2012年华南师范大学校赛初赛