| 2024 ICPC ShaanXi Provincial Contest |
|---|
| Finished |
There is a window with dimensions $$$100 \text{cm} \times 100 \text{cm}$$$ and $$$n$$$ square window decorations, each with a diagonal length of $$$2 \text{cm}$$$. Establish a coordinate system with the origin at the bottom left corner of the window $$$(0,0)$$$ and the top right corner at $$$(100,100)$$$. The center of the $$$i$$$-th window decoration is placed at a non-edge integer coordinate point $$$(x_i,y_i)$$$ $$$(1 \leq x_i,y_i \leq 99)$$$, and the diagonals of the window decorations are parallel to the coordinate axes.
Find out the total area of the window covered by at least one window decoration.
The first line contains an integer $$$n$$$ ($$$1 \leq n \leq 10000$$$).
Following are $$$n$$$ lines, each containing two integers $$$x_i,y_i$$$ ($$$1 \leq x_i,y_i \leq 99$$$), as described above.
Output a single line with a single real number: area of the window covered by at least one window decoration.
Your answer is considered correct if its absolute or relative error does not exceed $$$10^{−4}$$$. Formally, let your answer be $$$a$$$, and the jury's answer be $$$b$$$. Your answer is accepted if and only if $$$\frac{|a−b|}{\max (1,|b|)} \leq 10^{−4}$$$.
51 12 13 25 55 5
7.5
Explanation for the first example is shown as follows:
| Name |
|---|


