#include <stdio.h>
#include <string.h>

typedef struct str
{
    char str[19];
}str;

int main()
{
    str br[3];
    scanf("%s%s%s",&br[0].str,&br[1].str,&br[2].str);
    int i,j;
    char pom[19];
    for (i=0;i<2;++i)
    {
        for(j=i+1;j<3;++j)
        {
            if (strcmp(br[i].str,br[j].str)<0)
            {
                strcpy(pom,br[i].str);
                strcpy(br[i].str,br[j].str);
                strcpy(br[j].str,pom);
            }
        }
    }
    printf("%s%s%s",br[0].str,br[1].str,br[2].str);
    return 0;
}