
class Caesar

  def initialize
    string = $stdin.gets
    data = string.chomp.split(' ')
    val = 0
    data.each do |str|
      case str.size()
      when 3
        val = checker3(str)
      when 4
        val = checker4(str)
      end
      break if val
    end

    string.each_char do |ch|
      if ch != ' ' && ch != '.' && val
        print convert(ch,val)
      else
        print ch
      end
    end

    print "\n"
  end

  def convert(ch, shift)
    val = (ch.ord + shift)
    s = val%122
    if s < 97
      (97+s).chr
    else
      s.chr
    end
  end

  def checker4(string)
    list4 = ["this","that"]
    list4.each do |list|
      1.upto(25) do |s|
        index = 0
        string.each_byte do |ch|
          next if list[index].ord - convert(ch, s).ord != 0
          index += 1
        end
        return s if index == 4
      end
    end
    return false
  end

  def checker3(string)
    list3 = ["the"]
    list3.each do |list|
      1.upto(25) do |s|
        index = 0
        string.each_char do |ch|
          next if list[index].ord - convert(ch, s).ord != 0
          index += 1
        end
        return s if index == 3
      end
    end
    return false
  end
end

c = Caesar.new