Problem B
Translation or Rotation
Input: standard input
Output: standard output
Time Limit: 1 second
A line segment is given in the plane by its endpoints a = (a_{x},
a_{y})
and b = (b_{x},
b_{y}),
where a
is not equal to b.
The segment has been moved either by a counterclockwise rotation around some
point or by a translation and the final coordinates of its endpoints are known a' = (a'_{x},
a'_{y})
and b' = (b'_{x},
b'_{y}),
where endpoint a'
corresponds to the original endpoint a, and b' to b. Your
task is to decide whether the segment was rotated or translated and to report
your findings.
Input
Your program should read input from standard. Each line of the input contains 8 floatingpoint numbers, separated by spaces and giving the values of a_{x}, a_{y}, a'_{x}, a'_{y}, b_{x}, b_{y}, b'_{x}, b'_{y}. A line containing 8 zeros terminates the input and should not be processed.
For each line of input produce one line of output in the format given in the sample, where floatingpoint numbers are printed to 1 digits of the fractional part. The reported angle of rotation should be nonnegative and smaller than 360. In your computations, two floatingpoint numbers differing by less than 10e^{8} should be considered equal. Note that when the segment has not changed its position then report No move.
0 2 1 3 2 0 3 1 0 2 2 0 1 3 3 1 2.1 0 0 2.1 3 1 1 3 2.1 0 2.9238080804 0.7366059011 0 2.1 0.0347392304 0.9954452513 5 1 2 2 10 1 2 7 1 17 1 17 14 14 14 14 0 0 0 0 0 0 0 0

Translation by vector <1.0,1.0>. Translation by vector <2.0,2.0>. Rotation around (0.0,0.0) by 90.0 degrees counterclockwise. Rotation around (1.5,1.5) by 40.0 degrees counterclockwise. Rotation around (2.0,1.0) by 270.0 degrees counterclockwise. No move.

Problem
setter: Poitr Rudnicki, University of Alberta, Canada