Postcards
Valentine's Day was on the horizon, and Masha, along with her friends, decided to celebrate by making cards. To embellish these cards, Masha used circles of various sizes and a lace strip. The card-making process is straightforward: first, circles are glued onto a cardboard base. Then, a strip is glued around the perimeter of the resulting shape (or shapes, as there might be several) to cover all the joints between the circles and the cardboard. Masha needs to determine the length of the strip required to decorate one card. Can you help her with this calculation?
Input
The input consists of several lines, each describing a circle with three real numbers: x, y, and r, separated by spaces (-10 <= x, y <= 10, 0.001 <= r <= 10). Each number is given with a precision of 3 decimal places. The number of lines can vary from 1 to 50.
Output
The output should be a single number representing the total length of the strip needed to decorate the card. This number should be presented in fixed-point format with three decimal places.