#include<iostream>
using namespace std;
unsigned long long st(unsigned long long x, int n) {
	if (n==0) return 1;
	else if (n==1) return x;
	else if (n%2==0) return st(x*x,n/2);
	else return x*st(x*x,n/2);
}
int main() {
	ios_base::sync_with_stdio(false);
	cin.tie(0);
	cout.tie(0);
	unsigned long long a, b, c, pa, pb, pc, x[6], max=0; int i, abr=0, bbr=0, cbr=0;
	cin >> a >> b >> c;
	pa=a; pb=b; pc=c;
	while (a!=0) {
		a/=10;
		abr++;
	}
	while (b!=0) {
		b/=10;
		bbr++;
	}
	while (c!=0) {
		c/=10;
		cbr++;
	}
	x[0]=pa*st(10,bbr+cbr)+pb*st(10, cbr)+pc;
	x[1]=pa*st(10,bbr+cbr)+pc*st(10, bbr)+pb;
	x[2]=pb*st(10,abr+cbr)+pa*st(10, cbr)+pc;
	x[3]=pb*st(10,abr+cbr)+pc*st(10, abr)+pa;
	x[4]=pc*st(10,bbr+abr)+pa*st(10, bbr)+pb;
	x[5]=pc*st(10,bbr+abr)+pb*st(10, abr)+pa;
	for (i=0; i<6; i++)
	 if (x[i]>max) max=x[i];
	cout << max;
}