s = gets.chomp n = s.size ans = "" (n-1).downto(0) do |i| ss = s[i] if ss == "<" ans += ">" else ans += "<" end end puts ans