시간 제한 | 메모리 제한 | 제출 | 정답 | 맞힌 사람 | 정답 비율 |
---|---|---|---|---|---|
1 초 | 512 MB | 22 | 13 | 12 | 57.143% |
In a royal casino, there is a huge room with many slot machines. The casino manager feels that this room may be too easy to navigate and so the people have a good chance of getting out of the room without losing much money. This needs to be fixed, therefore the manager designed a complicated system of slot machine positions and straight aisles between them, so people get lost there more likely.
The room’s shape is roughly oval. If it was empty, the whole room could be observed from any inside point. Each of N slot machines in the room can be represented as a point and it is assigned some unique profit value. The manager wants the slot machines to be connected by aisles in the way described below.
There already are at least 3 machines built into the wall of the room. All these wall machines must be connected by straight aisles to create a closed perimeter path around the whole room. All of the remaining slot machines in the room (if there are any) will be inside the area enclosed by the perimeter path.
The room is to be divided by straight aisles into smaller separate areas, each enclosed by its own perimeter path. The division proceeds in two phases.
The Manager wants to assess the profitability of his design. For this purpose, he defines a socalled highly-profitable configuration, which is a maximum-size set of machines with a property that each pair of machines in the set is directly connected by an aisle.
The manager is specifically interested in three profitability parameters. The first profitability parameter is the size of one highly-profitable configuration. The second profitability parameter is the number of highly-profitable configurations that exist in the design. The third profitability parameter is the number of slot machines which are part of at least one highly-profitable configuration.
The first line of input contains a single integer N (3 ≤ N ≤ 105), the number of slot machines. Each of the next N lines contains two integers X, Y (0 ≤ X, Y ≤ 109), denoting the position of one slot machine in the room. The machines are listed in decreasing order of their profit value. The positions of no three machines are collinear.
Output the three profitability parameters.
6 8 2 6 8 4 9 3 5 3 0 1 5
4 1 4
6 1 1 6 1 1 6 6 6 3 2 4 5
4 2 6
ICPC > Regionals > Europe > Central European Regional Contest > CERC 2018 H번