Polygon Programming with Ease

Time Limit: 1000ms
Memory Limit: 30000KB
This problem will be judged on PKU. Original ID: 1940
64-bit integer IO format: %lld      Java class name: Main

Description

Read the statement of Problem 1939! Given a list of meeting locations as specified in the description of Problem 1939, you have to calculate the locations of the Foreign Offices.

Input

See the input specification of Problem 1939 for the format, and the output specification of Problem 1939 for the meaning of the input.

Output

See the output specification of Problem 1939 for the format, and the input specification of Problem 1939 for the meaning of the output.

Sample Input

5 14 2 20 4 18 12 12 18 10 10
3 -3 5 -2 5 -3 6
3 -2 10 5 10 -1 12

Hint

The relationship between the sample input and output polygons is illustrated in the figure below. Solid lines indicate the polygon joining the Foreign Offices, whereas dashed lines indicate the polygon joining the meeting locations. To generate further sample input you may use your solution to Problem 1939.

Source

Language: 
Theme: 
Share Code? 

Powered by NB231 | Current Style: .