2618: [Cqoi2006] Convex polygon Description counter-clockwise gives the vertex coordinates of
n convex polygons, and asks them to cross the area. For example, when n=2, two convex polygons such as:
The area of the intersecting portion is 5.233.
Input
The first line has an integer n, which represents the number of convex polygons, and the following describes each polygon in turn. The first line of the I polygon contains an integer mi, which represents the number of sides of the polygon, the following mi lines are two integers per line, and the coordinates of each vertex are given counterclockwise.
Output
The output file contains only a real number that represents the area of the intersection and retains three decimal places.
Sample Input2
6
-2 0
-1-2
1-2
2 0
1 2
-1 2
4
0-3
1-1
2 2
-1 0Sample Output5.233hint
100% data satisfies: 2<=n<=10,3<=mi<=50, integer in [ -1000,1000] per dimensional coordinate
"Bzoj 2618" 2618: [Cqoi2006] convex polygon (semi-planar intersection)