There are N enemy camps on a two-dimensional plane. Each camp builds one communication tower, and the tower of camp i takes every point within distance Ri of its position as its communication area Ai.
If the areas Ai and Aj touch or overlap, camp i and camp j communicate directly. Even without a direct link, two camps count as able to communicate when a chain of direct links connects them through other camps.
Camps that can communicate with each other move as one group. Count how many such groups there are.
The first line contains the number of test cases T. The T test cases follow.
The first line of each test case contains the number of enemy camps N (1≤N≤3000). Each of the next N lines contains the coordinates x, y (0≤x,y≤5000) of a camp and the radius R (0≤R≤5000) of its tower. All given numbers are integers.
For each test case, print the number of groups of enemy camps on one line.