#include <iostream>
#include <math.h>
using namespace std;

bool compare(int64_t num1, int64_t num2){
    if(num1 < 10 && num2 < 10){
        if(num1 > num2)
            return true;
        else{
            return false;
        }
    }

    int64_t curr_num1 = num1;
    int64_t curr_num2 = num2;

    int64_t first_num1_whole = curr_num1;
    int64_t first_num2_whole = curr_num2;

    int times1 = 0;
    int times2 = 0;

    int first_num1;
    int first_num2;

    while(first_num1_whole > 9){
        first_num1_whole /= 10;
        times1 ++;
    }
    while(first_num2_whole > 9){
        first_num2_whole /= 10;
        times2 ++;
    }

    first_num1 = first_num1_whole;
    first_num2 = first_num2_whole;

    curr_num1 -= (first_num1 * pow(10,times1));
    curr_num2 -= (first_num2 * pow(10,times2));


    if(first_num1 > first_num2){
        return true;
    }
    else if(first_num1 < first_num2){
        return false;
    }
    else{
        return compare(curr_num1,curr_num2);
    }

}

int main(){
    int64_t a,b,c;
    cin >> a >> b >> c;
    if(compare(a,b)){
        if(compare(a,c)){
            if(compare(b,c)){
                cout << a << b << c;
            }
            else{
                cout << a << c << b;
            }
        }
        else{
                cout << c << a << b;
        }
    }
    else{
        if(compare(b,c)){
            if(compare(a,c)){
                cout << b << a << c;
            }
            else{
                cout << b << c << a;
            }
        }
        else{
                cout << c << b << a;
        }
    }
    return 0;
}