Given a three-digit natural number . Find the sum of the largest and the smallest three-digit numbers that can be obtained by permuting the digits of .
A natural number n~(100 \le n \le 999).
Print the sum of the largest and the smallest three-digit numbers.
Example 1