luogu#P4703. 偷上网

    ID: 3577 远端评测题 2000ms 500MiB 尝试: 0 已通过: 0 难度: 6 上传者: 标签>计算几何Special JudgeO2优化枚举向量洛谷月赛

偷上网

Background

Description

Alice and Bob live in an l×ll \times l square house. Since Bob has recently become obsessed with "ge mo" (gémó), Alice decides to limit how often Bob can go online.

Alice has built nn wireless signal jammers. The ii-th jammer is located at (xi,yi)(x_i, y_i), with a blocking radius of ln\frac{l}{n}.

Bob’s internet addiction flares up and he can’t resist going online. He comes to you to find a position (x,y)(x, y) that is not covered by any of Alice’s wireless signal jammers.

Output Format

If such a position exists, output two numbers xx, yy (0x,yl0 \le x, y \le l), as described above. If there are multiple answers, output any one of them. If your output has distance to every jammer at least ln+106\frac{l}{n} + 10^{-6}, it will be considered correct.

Otherwise, output "GG".

1 1
0.000 0.000
0.999 0.999
1 2
1.000 1.000
GG
2 2
0.000 0.000
2.000 2.000
1.000 1.000

Hint

Translated by ChatGPT 5