name, a, b = gets.chomp.split a = a.to_i b = b.to_i if a == b name.slice! a else if a > b name.slice! a name.slice! b else name.slice! b name.slice! a end end puts name