P2950 [USACO09OPEN] Bovine Embroidery G

题目描述

Bessie has taken up the detailed art of bovine embroidery. Cows embroider a cloth mounted in a circular hoop of integer radius d (1

输入格式

\* Line 1: Two space-separated integers: N and d \* Lines 2..N+1: Line i+1 describes thread i with three integers: a, b, and c

输出格式

\* Line 1: One integer, on a line by itself, that is the count of pairs of threads that intersect.

说明/提示

The two lines are x=0 and y=0. The two lines intersect at (0,0), which is clearly with 1 of the origin.