Go: package main

import (
	"bufio"
	"os"
	"strings"
	"fmt"
	"reflect"
)

var scanner = bufio.NewScanner(os.Stdin)

func nextString() string {
	scanner.Scan()
	return scanner.Text()
}

func cipher(text string, direction int, int_shift int) string {
	shift, offset := rune(int_shift), rune(26)
	runes := []rune(text)
	for index, char := range runes {
		switch direction {
		case 1:
			if char >= 'a' && char <= 'z'-shift || char >= 'A' && char <= 'Z'-shift {
				char = char + shift
			} else if char > 'z'-shift && char <= 'z' || char > 'Z'-shift && char <= 'Z' {
				char = char + shift - offset
			}
		case -1:
			if char >= 'a'+shift && char <= 'z' || char >= 'A'+shift && char <= 'Z' {
				char = char - shift
			} else if char >= 'a' && char < 'a'+shift || char >= 'A' && char < 'A'+shift {
				char = char - shift + offset
			}
		}
		runes[index] = char
	}
	return string(runes)
}

func main() {
	for {
		infos := strings.Split(nextString(), " ")
		plain := make([]string, len(infos))
		if reflect.DeepEqual(infos, []string{}) {
			break
		}
		fmt.Println(infos)
		Decryption:
			for i := 0; i < 26; i++ {
				for j := range infos {
					plain[j] = cipher(infos[j], 1, i)
				}
				for j := range plain {
					if plain[j] == "this" || plain[j] == "that" || plain[j] == "the" {
						break Decryption
					}
				}
			}
			fmt.Println(strings.Join(plain, " "))
	}
}

Python: x=[i for i in input()]
i=0
y=[0 for i in range(4)]
dif1=0
while(i<len(x)-1):
    s=0
    for j in range(4):
        if (x[j]!=' ')and (x[j]!='.')and (x[j]!='\n'):
            y[j]=x[j]
            s=j
        else:
            s=j
            break       
    if s==3 or s==2:
        dif1=ord(y[0])-ord('t')
        dif2=ord(y[1])-ord('h')
        if dif1==dif2:
            break;
        else:
            i=i+s+1
            
    else:
        i=i+s+1
print(dif1)
for i in range(len(x)):
    if (x[i]!=' ')and (x[i]!='.')and (x[i]!='\n'):
        print(chr(int(ord(x[i]))-dif1),end="")
    else:
        print(x[i],end="")

Python: import sys
for s in map(lambda l: list(l.rstrip()), sys.stdin.readlines()):
    while True:
        for i, c in enumerate(s):
            char_code = ord(c)
            if 97 <= char_code <= 122:
                char_code = char_code+1 if char_code < 122 else 97
                s[i] = chr(char_code)

        _s = "".join(s)
        if "this" in _s or "the" in _s or "that" in _s:
            print(_s)
            break

Python: li = 'abcdefghijklmnopqrstuvwxyz'

while True:
    try:
        s = input()
    except:
        exit()

    for d in range(1, 27):
        t = s[:-1].translate(str.maketrans(li, li[d:] + li[:d]))
        if 'the' in t or 'this' in t or 'that' in t:
            print(t + '.')
            break

Python: # coding: utf-8

def contain_the(char):
	for i in range(len(char)):
		try:
			if char[i] == 't' and char[i+1] == 'h' and (char[i+2] == 'e' or (char[i+2] == 'i' and char[i+3] == 's') or (char[i+2] == 'a' and char[i+3] == 't')):
				return 1
		except IndexError:
			return 0

while True:
	try:
		data = raw_input()
		delta = 1
		while True:
			char = ""
			for i in range(len(data)):
				if data[i] != '.' and data[i] != ' ':
					char += chr(ord(data[i]) - delta)
				else:
					char += data[i]
			if (contain_the(char) == 1):
				print(char)
				break
			else:
				delta += 1
			print("*")
	except EOFError: #なぜかEOFErrorにならない
		print("**")
		break

Python: import sys

words = list('abcdefghijklmnopqrstuvwxyz')
for line in sys.stdin:
    txt = ''
    for sft in range(0,len(words)):
        txt = ''.join([words[words.index(c) - len(words) + sft] if c in words else c for c in line])
        if 'the' in txt.split() or 'this' in txt.split() or 'that' in txt.split():
            break
    print(txt)

Python: t = ord("t")
z = ord("z")
a = ord("a")
 
def _decode(tv, v):
    spam = ord(v)
    if not (a <= spam <= z):
        return v
 
    x = t - ord(tv)
    y = spam + x
 
    if y > z:
        y = a + (y % z) - 1
    elif y < a:
        y = z - (a - y - 1)
 
    return chr(y)
 
while 1:
    try:
        txt = input()
        for s in [x for x in txt.split() if 3 <= len(x) <= 4]:
            tv = s[0]
            dec_val = ''.join(list(map(lambda x:_decode(tv,x),s)))
 
            if (dec_val in ('this', 'the', 'that')):
                print(''.join(list(map(lambda x:_decode(tv,x),txt))))
                break
    except:
        break

Python: # -*- coding: utf-8 -*-

import sys
import codecs

for line in sys.stdin:
    for i in range(0, 26):
        ans = ""
        for j in range(len(line)):
            a = ord(line[j])
            if ord('a') <= a <= ord('z'):
                if a-i >= ord('a'):
                    ans = ans + chr(a-i)
                else:
                    ans = ans + chr(a-i+26)
            else:
                ans = ans + line[j]
        if "the" in ans or "this" in ans or "that" in ans:
            break
    sys.stdout.write(ans)

Python: s = input()
a = "".join([chr(97 + i) for i in range(26)])
b = "".join([a[i -1] for i in range(26)])
x = str.maketrans(a, b)
while True:
    s = s.translate(x)
    if "the" in s or "that" in s or "this" in s:
        print(s)
        break

Python: import sys

idx2alpha = {idx:s for idx,s in enumerate('abcdefghijklmnopqrstuvwxyz .\n')}
alpha2idx = {s:idx for idx,s in enumerate('abcdefghijklmnopqrstuvwxyz .\n')}

def rotate(s):
    idx = [next_w(alpha2idx.get(w)) for w in s]
    new_s = [idx2alpha.get(i) for i in idx]
    return ''.join(new_s)

def next_w(w_idx):
    if 25 < w_idx:
        return w_idx
    w_idx += 1
    return w_idx % 26

def decrypt(s):
    for _ in range(26):
        if 'the' in s or 'this' in s or 'that' in s:
            return s
        else:
            s = rotate(s)
    return 'Failed to decript!'

def run():
    for line in sys.stdin:
        print(decrypt(line.strip()))

if __name__ == '__main__':
    run()

Python: s = input()
a = "".join([chr(97 + i) for i in range(26)])
b = "".join([a[i - 24] for i in range(26)])
x = str.maketrans(a, b)
while True:
    s = s.translate(x)
    if "the " in s or "that " in s or "this " in s:
        print(s)
        break

Python: def judge_the(word):
	length=ord('t')-ord(word[0])
	if ord('h')-ord(word[1])==ord('e')-ord(word[2])==length:
		return True
	else:
		return False

def judge_this(word):
	length=ord('t')-ord(word[0])
	if ord('h')-ord(word[1])==ord('i')-ord(word[2])==ord('s')-ord(word[3])==length:
		return True
	else:
		return False

def judge_that(woed):
	length=ord('t')-ord(word[0])
	if ord('h')-ord(word[1])==ord('a')-ord(word[2])==ord('t')-ord(word[3])==length:
		return True
	else:
		return False

def change(string,l):
	string1=""
	for i in range(len(string)):
		C=ord(string[i])+l
		if C<97:
			C+=26
		elif C>122:
			C-=26
		string1+=chr(C) if string[i]!='.' else '.'
	return string1



while True:
	try:
		A=list(map(str,input().split()))
		l=int()
		for i in A:
			if len(i)==3:
				if judge_the(i)==True:
					l=ord('e')-ord(i[2])
					break
			elif len(i)==4:
				if judge_this(i)==True :
					l=ord('i')-ord(i[2])
					break
				elif judge_that(i)==True:
					l=ord('a')-ord(i[2])
					break
		else:
			break#while?????????
		Ans=[""]*len(A)
		for i in range(len(A)):
			Ans[i]=change(A[i],l)

		print(" ".join(Ans))
	except EOFError:
		break