The Math of Sailing

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

문제

Captain Polycarp has been dreaming about owning a three-mast sailing ship since he was a child. And at last, his dream is about to come true, he has saved enough money and bought a beautiful caracca "Pulcheria". However he overlooked the fact that it was sold without any sails on, so now he has to find them separately.

Caracca should have exactly four sails: one on the back mast, one on the front one, and two on the middle one. And Polycarp, coincidentally, has exactly four pieces of fabric with sizes t_1t\_1, t_2t\_2, t_3t\_3 and t_4t\_4. Polycarp can use those fabric pieces as sails in any order, making them smaller beforehand, if needed.

Let's denote the size of the front mast sail as a_1a\_1, the sizes of the middle mast sails as a_2a\_2 and a_3a\_3 and the size of the back mast one as a_4a\_4. The maneuverability of the ship is calculated as a_1a_4+a_2+a_3a\_1 a\_4 + a\_2 + a\_3 and its stability is calculated as a_1+a_4+a_2a_3a\_1 + a\_4 + a\_2 a\_3.

For the caracca to walk the sea safely captain has to adjust the sails in such a way that the maneuverability of the ship is equal to its stability. And for maximum comfort, these two values should be as large as possible.

To sum it up, Polycarp has to lower the values of t_1,,t_4t\_1, \ldots, t\_4 if needed, and then distribute the resulting sizes among the four sails in any order so that the following equality will hold and both of its sides will be maximal possible: a_1a_4+a_2+a_3=a_1+a_4+a_2a_3a\_1 a\_4 + a\_2 + a\_3 = a\_1 + a\_4 + a\_2 a\_3.

Help him find a way to make the ship's maneuverability equal to its stability while maximizing both of these equal values.

입력

The first and only line of input contains four integers t_1t\_1, t_2t\_2, t_3t\_3 and t_4t\_4 --- the sizes of pieces of fabric Polycarp has (1t_i1041 \leq t\_i \leq 10^4).

출력

In the first line of output print pp --- a permutation of integers from 11 to 44, the ii-th number in it should specify from which piece of fabric was the ii-th sail created. For example, if the second sail was created by decreasing the size of the fourth piece of fabric then p_2=4p\_2 = 4.

In the second line print space-separated values a_1a\_1, a_2a\_2, a_3a\_3 and a_4a\_4 --- the resulting sizes of the sails (1a_1,a_2,a_3,a_41041 \leq a\_1, a\_2, a\_3, a\_4 \leq 10^4). These values don't have to be integers.

Your answer is accepted if the absolute error of the resulting maneuverability and stability compared to the correct answer does not exceed 21062 \cdot 10^{-6} and both of those values differ from each other by no more than 10610^{-6}.