|시간 제한||메모리 제한||제출||정답||맞은 사람||정답 비율|
|5 초||512 MB||61||21||10||25.000%|
You are a newly designed and created robot. As a robot, you are excellent at shooting lasers: your lasers always go perfectly straight, go infinitely far, and are infinitely thin. To test you, the scientist who made you set out a number of targets for you to hit with your laser beam. The targets (point-like objects) are set up in a large, open room.
Unfortunately, you are running low on battery. You only have enough charge left to fire two shots. The targets are transparent, so you might be able to shoot multiple targets with your laser beam. In fact, you are able to hit an infinite number of targets with a single shot, as long as they are on a straight line. In addition, you can move anywhere before and between the two shots. Can you figure out if it is possible to hit all targets with at most two shots from your laser beams?
The first line contains an integer N, satisfying 1 ≤ N ≤ 100 000, the number of targets.
The following N lines each contain two integers Xi and Yi, satisfying −109 ≤ Xi, Yi ≤ 109. Each pair (Xi, Yi) specifies the coordinates of one of the N targets. No two targets are placed at the same coordinates.
You may assume that height does not play a role in this problem.
Output a single line containing a single word: “success” if it is possible to line up the two shots so that they hit all the targets, and “failure” if it is not.
6 -1 0 0 0 1 0 -1 1 0 2 1 1
6 1 1 3 5 0 -1 1 0 5 0 0 0