#P6505. Run Away
Run Away
Description
In the 2D Cartesian coordinate system, there is a rectangle whose bottom-left corner is at and top-right corner is at , with its sides parallel to the coordinate axes.
Inside the rectangle, there are given points. The coordinates of the -th point are .
Please find a point inside the rectangle such that its distance to the nearest given point is as large as possible. You only need to output the value of this distance.
Input Format
The first line contains three integers .
The next lines each contain two integers .
Output Format
Output one real number in a single line, representing the maximum possible value of the nearest distance.
Your answer will be considered correct if its absolute error or relative error is within of the standard output.
100 100 4
10 10
10 90
90 10
90 90
56.5685424949
3000 3000 4
1200 85
63 2500
2700 2650
2990 100
1601.8805541731
Hint
Sample Explanation 1
The required point is at , and its distance to the nearest given point is .
Constraints
- For of the testdata, .
- For of the testdata, , , , .
The input may contain duplicate points.
Source: IOI 2006 CTT paper, "Wang Dong — A Brief Analysis of the Construction and Applications of Planar Voronoi Diagrams".
Translated by ChatGPT 5
京公网安备 11011102002149号