while gets do
  str = $_.chomp
  alp = ('a'..'z').to_a

  26.times do |i|
    break if str =~/the|that|this/
    str.length.times do |j|
      next if str[j] !~ /[a-z]/
      str[j] = alp[(alp.index(str[j])+1)%26]
    end
  end

  puts str
end