#include <stdio.h>


int main()
{int i, a, b, c, ax, bx, cx, max, min, ay, by, cy;
scanf("%d %d %d", &a, &b, &c);
ax = a;
bx = b;
cx = c;
while(ax > 9){
    ax /= 10;

    }

while(bx > 9){
    bx /= 10;

    }
while(cx > 9){
    cx /= 10;

    }
ay = ax;
by = bx;
cy = cx;

max = 0;
if(ax > max)
    max = ax;

if(bx > max)
    max = bx;

if(cx > max)
    max = cx;


if(ax == max)
    max = a;
if(bx == max)
    max = b;
if(cx == max)
    max = c;

min = ay;
if(by < min)
    min = by;
if(cy < min)
    min = cy;

if(ay == min)
    min = a;
if(by == min)
    min = b;
if(cy == min)
    min = c;




if(a != min && a != max)
    i = a;
if(b != min && b != max)
    i = b;
if(c != min && c != max)
    i = c;
  printf("%d%d%d", max,i, min);









    return 0;
}