gHey, whatfs up? Itfs already 30 minutes past eleven!h
gIfm so sorry, but actually I got lost. I have no idea where I am now at all and I got tired wandering around. Please help!h
- Today you came to the metropolis to play with your friend. But she didnft show up at the appointed time. What happened to her? After some uncomfortable minutes, finally you managed to get her on line, and have been just notified that shefs been lost in the city.
You immediately told her not to move, and asked her what are around her to figure out where she is. She told the names of some famous land marks, in the order where she caught in her sight while she made a full turn counterclockwise without moving around.
Fortunately, today you have a map of the city. You located all the land marks she answered on the map, but want to know in which district of the city shefs wandering.
Write a program to calculate the area where she can be found, as soon as you can!
Each input case is given in the format below:
N x1 y1 ... xN yN l1 . . . lN
An integer N in the first line specifies the number of land marks she named (N ≤ 10). The following N lines specify the x- and y-coordinates of the land marks in the city. Here you modeled the city as an unbounded two- dimensional plane. All coordinate values are integers between 0 and 100, inclusive. The last line of a test case specifies the order in which she found these land marks in a counterclockwise turn.
A single line containing zero indicates the end of input. This is not a part of the input and should not be processed.
Your program should output one line for each test case.
The line should contain the case number followed by a single number which represents the area where she can be found. The value should be printed with the fifth digit after the decimal point, and should not contain an absolute error greater than 10-5 .
If there is no possible area found under the given condition, output gNo areah in a line, instead of a number. If you cannot bound the area, output gInfinityh.
8 1 0 2 0 3 1 3 2 2 3 1 3 0 2 0 1 1 2 3 4 5 6 7 8 8 1 0 2 0 3 1 3 2 2 3 1 3 0 2 0 1 4 3 2 1 8 7 6 5 4 0 0 1 0 1 1 0 1 1 2 3 4 0
Case 1: 10.00000 Case 2: No area Case 3: Infinity