The sport of curling is played in ends. In an end, two teams throw eight rocks each toward a circular target. The centre of the target is called the tee. The team that scores is the team whose rock is closest to the tee. The score for that team is the number of rocks belonging to it that are closer to the tee than any other rock from the opposing team, and no more than six feet from the tee. Rocks within .001 feet of the same distance to the tee are considered to be tied. A rock is not considered to be closer to the tee than a rock with which it is tied. If the nearest rocks for the two teams are tied or both more than six feet from the tee, the end is declared to be a blank end, and there is no score.
Assume that the tee is at at the location whose coordinates are (0,0). The position of each rock is given as coordinate pairs (x,y) where x and y are in feet. For each of several games you are to determine which team wins, and its score.
1 1 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 0.1 1 0.9 -0.9 8 -8 -7 7 6 5 5 4 4 5 0 0
B 3