#include <cmath>
#include <iostream>
using namespace std;

long long broj[10];
long long stepen[15];

int main() {
    long long a, b, c;
    cin >> a >> b >> c;
    long long a1=a, b1=b, c1=c;
    long long brA=0, brB=0, brC=0;
    while(a>0)
    {
        brA++;
        a/=10;
    }
    while(b>0)
    {
        brB++;
        b/=10;
    }
    while(c>0)
    {
        brC++;
        c/=10;
    }
    a=a1;
    b=b1; 
    c=c1;
    
    long long br=brA+brB+brC;
    if(br<3)
        br=3;
    
    stepen[0]=1;
    for(int i=1; i<=10; i++)
        stepen[i]=stepen[i-1]*10;
    
    broj[1]=a*stepen[br-brA]+b*stepen[br-brA-brB]+c;
    broj[2]=a*stepen[br-brA]+c*stepen[br-brA-brC]+b;
    broj[3]=b*stepen[br-brB]+a*stepen[br-brB-brA]+c;
    broj[4]=b*stepen[br-brB]+c*stepen[br-brB-brC]+a;
    broj[5]=c*stepen[br-brC]+a*stepen[br-brC-brA]+b;
    broj[6]=c*stepen[br-brC]+b*stepen[br-brC-brB]+a;
    
    long long maxbroj=broj[1];
    for(int i=1; i<=6; i++)
    {
        if(broj[i]>maxbroj)
            maxbroj=broj[i];
    }
    
    cout << maxbroj;
    
    return 0;
}