Fragmentation
Andrey, a fifth grader, is learning about fractions in his math class. Today, the lesson focused on adding fractions, and the teacher assigned a challenging homework problem.
Given four positive integers a, b, c, and d, we define their "fractioning" as the sum:
Your task is to rearrange these four numbers to minimize their fractioning. Help Andrey find the order that results in the smallest possible fractioning.
Input
The input consists of a single line containing four positive integers — a, b, c, and d (1 ≤ a,b,c,d ≤ 10^9
).
Output
Output the four numbers in a permutation that minimizes their fractioning. If there are multiple permutations that achieve the minimum, you may output any one of them.
Examples
Note
In the first example, arranging the numbers in this order results in the fractioning:
It is not possible to achieve a smaller value.
In the second example, the fractioning is: