Go: package main

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

var scanner = bufio.NewScanner(os.Stdin)

func main() {
	for scanner.Scan() {
		var result string
		line := scanner.Text()
		key := make(map[string]string)

		var i int32
		for ; i < 52; i++ {
			makeKey(key, i)
			result = decode(key, line)

			if strings.Contains(result, "the") {
				break
			} else if strings.Contains(result, "this") {
				break
			} else if strings.Contains(result, "that") {
				break
			}
		}

		fmt.Println(result)
	}
}

func makeKey(key map[string]string, shift int32) {
	for i := 'a'; i <= 'z'; i++ {
		cipher := (i + shift)
		if cipher > 'z' {
			cipher = cipher%'z' + 'a' - 1
		} else if cipher < 'a' {
			cipher = cipher + ('z' - 'a') + 1
		}
		key[string(i)] = string(cipher)
	}
}

func decode(key map[string]string, cipher string) string {
	var result string
	for _, v := range cipher {
		if key[string(v)] != "" {
			result += key[string(v)]
		} else {
			result += string(v)
		}
	}
	return result
}

Python: import sys
for line in sys.stdin:
    for i in range(26):
        search = ""
        for idx in line:
            if 97 <= ord(idx) <= 122:
                if ord(idx) + i <= 122:
                    search += chr(ord(idx) + i)
                else:
                    search += chr(ord(idx) + i - 26)
            else:
                search += idx
        if 'the' in search or 'this' in search or 'that' in search:
            print(search)
            quit

Python: def ceasar(sentence, n):
    sentence = list(sentence)
    for i in range(len(sentence)):
        if sentence[i] in alphabets:
            sentence[i] = alphabets[(alphabets.index(sentence[i]) + n) % 26]
    return ''.join(sentence)
def is_right(sentence):
    words = '.'.join(sentence.split(' ')).split('.')
    return 'the' in words or 'this' in words or 'that' in words
alphabets = 'abcdefghijklmnopqrstuvwxyz'
while True:
    try:
        line = input()
        if line == '*':
            break
    except:
        break
    for i in range(26):
        if is_right(ceasar(line, i)):
            print(ceasar(line, i))
            break

Python: while 1:
    try:
        n=float('inf')
        s=raw_input().strip('.').split()
        for i in xrange(26):
            for j in s:
                r=[]
                for k in j:
                    r.append(chr(97+((ord(k)+i)/123)*(ord(k)+i-122)))
                if "".join(r)=="this" or "".join(r)=="that" or "".join(r)=="the":
                    n=i
            if n!=float('inf'):
                break
        ans=[]
        for i in s:
            splitans=[]
            for j in i:
                splitans.append(chr(97+((ord(j)+n)/123)*(ord(j)+n-122)))
            ans.append(''.join(splitans))
        print(' '.join(ans)+'.')
    except:
        break

Python: def main():
    ex =[ord(".")]
    while True:
        try:
            words = input().split()
        except:
            break
        bl = False
        for i in range(1,26):
            ans = ""
            for word in words:
                s = ""
                for string in word:
                    os = ord(string)
                    if os in ex:
                        s = s + string
                    else:
                        if os - i < 97:
                            s += chr(122 - (97 - (os - i)))
                        else:
                            s += chr(os - i)
                if s in ("the", "this", "that", "this.", "that."):
                  bl = True
                ans += " " + s
            if bl:
                break
        print(ans[1::])

if __name__ == "__main__":
    main()

Python: 
import string
import sys

def CaesarCipher():
    
    low=string.ascii_lowercase
    
    for cry in sys.stdin: 
        for i in range(1,27):
            
            dec=cry.translate(str.maketrans(low,low[i:]+low[:i]))
    
            if 'this' in dec or 'that' in dec or 'the' in dec:
                print(dec[:-1])
            
                
    
CaesarCipher()

Python: # Aizu Problem 0017: Caesar Cipher
#
import sys, math, os

# read input:
PYDEV = os.environ.get('PYDEV')
if PYDEV=="True":
    sys.stdin = open("sample-input.txt", "rt")

def caesar_decrypt(N, cipher):
    text = ""
    for char in cipher:
        if 'a' <= char <= 'z':
            k = (ord(char) - 97 - N) % 26
            text += chr(97 + k)
        else:
            text += char
    return text


for cipher in sys.stdin:
    cipher = cipher.strip()
    for k in range(26):
        decrypted = caesar_decrypt(k, cipher)
        if "this" in decrypted or "the" in decrypted or "that" in decrypted:
            print(decrypted)
            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
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('t')-ord(i[0])
					break
		for i in A:
			for c in i:
				C=ord(c)+l
				if C<0:
					C+=26
				if c=='.':
					print(c,end="")
				else:
					print(chr(ord(c)+l),end="")
			if i!=A[-1]:
				print(end=" ")
			else:
				print()
	except EOFError:
		break

Python: import sys

for line in sys.stdin:
  if line == '\r' or line == '\n':
    break
  slist = list(line)
  slist.pop()
  while True:
    for i in range(len(slist)):
      if slist[i] == ' ' or slist[i] == '.' or slist[i] == ',':
        continue
      elif slist[i] == 'z':
        slist[i] = 'a'
      else:
        slist[i] = chr(ord(slist[i]) + 1)
    s = ''.join(slist)
    if "the" in s or "this" in s or "that" in s:
      print(s)
      break

Python: while 1:
    try:
        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[i+j]!=' ')and (x[i+j]!='.')and (x[i+j]!='\n'):
                    y[j]=x[i+j]
                else:
                    s=j
                    break
            k=i
            while(1):
                if s != 0:
                    break
                else:
                    if (x[i]==' ') or (x[i]=='.')or (x[i]=='\n'):
                        k=i-k
                        break
                i=i+1
            if s==3 or s==2:
                dif1=ord(y[0])-ord('t')
                dif2=ord(y[1])-ord('h')
                if dif1==dif2:
                    if s==2 and ord(y[2])-dif1==ord('e'):
                        break
                    else:
                        if ord(y[2])-dif1==ord('a') :
                            if y[0]==y[3]:
                                break
                            else:
                                i=i+k+1
                        elif ord(y[2])-dif1==ord('i'):
                            if ord(y[3])-dif1==ord('s'):
                                break
                            else:
                                i=i+k+1
                        else:
                            i=i+k+1
                else:
                    i=i+s+1
                    
            else:
                i=i+s+1
        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="")
                
    except EOFError:
        break

Python: import sys

def caesar(c):
  if c == "z":
    return "a"
  elif c == "Z":
    return "A"
  elif 65 <= ord(c) and ord(c) <= 122:
    return chr(ord(c)+1)
  else:
    return c

while True:
  text = sys.stdin.readline()
  if not text: break
  text = text.rstrip()
  while True:
    if "the" in text or "this" in text or "that" in text:
      print(text)
      break
    text = "".join(map(caesar, list(text)))