#include <iostream>
#include <string>

using namespace std;

int main()
{
    string a, b, c;
    string answ;
    cin >> a >> b >> c;

    if(a >= b && a >= c)
    {
        answ = a;

        if(b >= c)
        {
            answ+=b + c;
        }
        else
        {
            answ+=c + b;
        }
    }
    else if (b >= a && b >= c)
    {
        answ = b;

        if(a >= c)
        {
            answ+=a + c;
        }
        else
        {
            answ+=c + a;
        }
    }
    else if (c >= a && c >= b)
    {
        answ = c;

        if(b >= a)
        {
            answ+=b + a;
        }
        else
        {
            answ+=a + b;
        }
    }
    cout << answ;
    return 0;
}