Circus Performance
시간 제한1초메모리 제한1024 MB
모든 n명의 곡예사를 일렬로 세울 때 연속한 세 명 (i,j,k)마다 a_i*b_j + a_j*b_k + a_k*b_i >= a_k*b_j + a_j*b_i + a_i*b_k를 만족하도록 순서를 정한다.
문제
A very famous circus is in the city! There are exactly acrobats in the circus, and this time they prepared a special show in honor of the SPb Team School Programming Olympiad 2022.
It is known that the -th acrobat has a height equal to and weight equal to . Any three acrobats can get together and perform an unusual stunt. If acrobats with numbers , and perform a stunt, the efficiency of the stunt is estimated as .
A circus' trainer considers an ordered trio of acrobats good if the efficiency of their stunt is no less than if they are arranged in reverse order .
For the final act of the show the trainer wants line up all acrobats so that any triple of consecutive acrobats would be good. Help him with this difficult task!
입력
The first line of input contains an integer representing the number of acrobats in the circus ().
In the -th of the following lines there are two space-separated integers and --- the height and weight of the -th acrobat ().
출력
Print different integers from to --- the numbers of acrobats in the order in which they should be lined up.