A complicated machine is made of n wheels, numbered 1 to n. They are really cogwheels, but the cogs are so small that each wheel is modeled as a circle in the plane. Every wheel spins around its own center.
Two wheels never overlap, which means they share no interior point, but they may touch. When two wheels touch and one of them turns, the other turns as well, because their tiny cogs are locked together.
A force is applied to wheel 1 and to no other wheel, turning it exactly one turn per minute, clockwise. Find how fast every other wheel turns. You may assume the machine is not jammed, so the motion described by the input really happens.
The first line contains the number of test cases T.
Each test case starts with a line holding the number of wheels n (1≤n≤1000). Each of the next n lines contains three integers x, y and r (−10000≤x,y≤10000; 1≤r≤10000), where (x,y) is the center of the wheel and r is its radius. The wheels are numbered 1 to n in the order they are given.
For each test case print n lines. Line i describes how wheel i moves.
If the wheel turns, print p/q clockwise or p/q counterclockwise, where the irreducible fraction p/q is the number of turns per minute. If q is 1, print the integer p instead of the fraction. If the wheel stands still, print not moving.