当前你的浏览器版本过低,网站已在兼容模式下运行,兼容模式仅提供最小功能支持,网站样式可能显示不正常。
请尽快升级浏览器以体验网站在线编辑、在线运行等功能。

建议使用的浏览器:

谷歌Chrome 火狐Firefox Opera浏览器 微软Edge浏览器 QQ浏览器 360浏览器 傲游浏览器

1688:Dolphin Pool

题目描述
In a newly constructed dolphin pool in the Kish island in Persian Gulf, one of the fun games is as follows: the game director throws several plastic rings in the pool such that center of no ring lies inside any other ring, and no two rings are tangent. The dolphins are trained to jump out on the director's whistle through the closed areas that are completely outside the rings, one dolphin from one such area. The dolphins jump out if and only if the number of closed areas exactly equals to the number of dolphins.

You are to write a program to given the following input/output description, finds the number of closed areas between rings to help the dolphins decide to jump out or not.
输入解释
The first line includes the number of test cases (at most 20). Each test case data has an integer N (1 <= N <= 20), the number of plastic rings, in its first line. Following the first line there are N lines, each containing three integers, the first and second being the x and y coordinates of the circle of the ring, and the third is its radius. Coordinates are positive integers less than 1000 and the radius is in the range 1...100.
输出解释
For each test case, there must be one line in the output including the number of closed areas in that test case.
输入样例
2
4
100 100 20
100 135 20
135 100 20
135 135 20
1
10 10 40
输出样例
1
0

该题目是Virtual Judge题目,来自 北京大学POJ

题目来源 Tehran 2000

源链接: POJ-1688

最后修改于 2020-10-29T06:11:10+00:00 由爬虫自动更新

共提交 0

通过率 --%
时间上限 内存上限
1000 10000