How to Learn You Score

아직 제출이 없습니다시간 제한1초메모리 제한512 MB

문제

Petya participates in such contest that the participants only learn results of judging their submissions after the end of the contest.

There are nn problems numbered from 11 to nn in the contest. For each problem he has made a submission. After the contest he was very eager to learn his points and his place. But the results would only be published at the closing ceremony, which is a few hours away.

Petya decided to find out his result before that: to get his points for each problem from the jury, he would ask weird questions. Let Petya's points be c_1,c_2,,c_nc\_1, c\_2, \ldots, c\_n for problems 1,2,,n1, 2, \ldots, n, respectively. Petya doesn't know these numbers and wants to find them out.

Petya chooses three distinct numbers of the problems and asks the jury to tell him the sum of the minimum and the maximum points he received for these three problems. Fortunately, the jury answers such queries. Formally, if he queries about ii, jj, kk, he gets min(c_i,c_j,c_k)+max(c_i,c_j,c_k)min(c\_i, c\_j, c\_k) + max(c\_i, c\_j, c\_k).

Petya still doesn't know how to find out all his points. Help him find out c_1,c_2,,c_nc\_1, c\_2, \ldots, c\_n, by making no more than 4n4n queries to the jury.

힌트

In this sample, there are 55 problems, and Petya got 11, 00, 22, 11, 33 points for the problems. If he queries about problems 11, 22, 33, his minimum points among them is 00 (for the 22-nd problem), and his maximum is 22 (for the 33-rd problem). Thus, the jury will answer 2=0+22 = 0 + 2 to that query.