function Main(input){
    input = input.split(" ")
    var array = new Array()
    for(var i = 0;i < 3;i++){
        array.push(parseInt(input[i],10))
    }

    console.log(array[0] + array[1] + array[2] + 9 * Math.max(...array))
}

Main(require("fs").readFileSync("/dev/stdin","utf8"))
