SP2835 MLE - Memory Limit Exceeded

Description

Given **n** points on X-Y plane. To each point, you are to find the other point who is closest to it with respect to the Euclidean distance.

Input Format

**T** (

Output Format

For each test case, output **n** lines. The i-th of them should contain the squared distance between the i-th point from the input and its nearest neighbour.