Go: package main

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

var scanner = bufio.NewScanner(os.Stdin)

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

func incrementByte(b byte) byte {
	if b >= 97 && b < 122 {
		return b + 1
	} else if b == 122 {
		return 97
	}
	return b
}

func main() {
	scanner.Split(bufio.ScanLines)

	for {
		line := nextString()
		if len(line) == 0 {
			break
		}
		for i := 0; i <= 26; i++ {
			decoded := []byte{}
			for j := 0; j < len(line); j++ {
				decoded = append(decoded, incrementByte(line[j]))
			}
			line = string(decoded)
			if strings.Contains(line, "the") || strings.Contains(line, "this") || strings.Contains(line, "that") {
				fmt.Println(line)
				break
			}
		}
	}
}

C++: #include <bits/stdc++.h>
#define FOR(i,a,b) for(int i=(a);i<(b);i++)
#define RFOR(i,a,b) for(int i=(b) - 1;i>=(a);i--)
#define REP(i,n) for(int i=0;i<(n);i++)
#define RREP(i,n) for(int i=n-1;i>=0;i--)

#define PB push_back
#define INF INT_MAX/3
#define ALL(a) (a).begin(),(a).end()
#define CLR(a) memset(a,0,sizeof(a))

typedef long long int ll;

using namespace std;

int main(){

    string s[] = {"the","this","that"};
    string in;
    while(true){
	getline(cin,in);
	if(cin.eof()) break;
	bool f = false;
	int d = 1;
	REP(i,30){

	    f = true;
	    REP(i,in.size()){
		if(in[i] == '.' || in[i] == ' ' || in[i] == '\n') continue;
		in[i]= (char)( 'a' + ( (int)(in[i] - 'a') + d) % 28);
	    }
	    vector<bool> flgs(3,false);
	    for(int i=0;i<in.size();i++){
		REP(j,3){
		    if(in.substr(i,s[j].size()) == s[j]) flgs[j] = true;
		}
	    }
	    if(flgs[0] || flgs[1] || flgs[2]) break;
	}
	cout << in << endl;
    }

    return 0;
}

C++: /*0017 written by iPhone*/
#include <iostream>
#include <string>
#include <cstring>

using namespace std;

int main(){
    string s;
    while(getline(cin, s)){
        for(int i = 0; i < s.size(); i++) s[i]++;
        if(strstr(s.c_str(), "the") || strstr(s.c_str(), "this") || strstr(s.c_str(), "that") ) cout << s, return 0;
    }
    return 0;
}

C++: #include<iostream>
#include<string>
using namespace std;
string S; char T[29] = "abcdefghijklmnopqrstuwxyz. "; int x[100000];
int main() {
	getline(cin, S);
	for (int i = 0; i < 100000; i++) { x[i] = 100000; }
	for (int i = 0; i < S.size(); i++) {
		for (int j = 0; j < 28; j++) {
			if (T[j] == S[i]) {
				x[i] = j;
			}
		}
	}
	for (int i = 0; i < 26; i++) {
		for (int i = 0; i < S.size(); i++) {
			if (x[i] == 19 && x[i + 1] == 7 && x[i + 2] == 8 && x[i + 3] == 18) {
				goto E;
			}
			if (x[i] == 19 && x[i + 1] == 7 && x[i + 2] == 0 && x[i + 3] == 18) {
				goto E;
			}
			if (x[i] == 19 && x[i + 1] == 7 && x[i + 2] == 4) {
				goto E;
			}
		}
		for (int i = 0; i < S.size(); i++) {
			if (x[i] < 26) {
				x[i]++;
				x[i] %= 26;
			}
		}
	}
E:;
	for (int i = 0; i < S.size(); i++) {
		cout << T[x[i]];
	}
	cout << endl;
}

C++: #include <cstdio>
#include <cstdlib>
#include <iostream>
#include <string>
#include <cmath>
#include <algorithm>
#include <vector>
#include <queue>
#include <stack>
#include <map>

using namespace std;
typedef long long ll;

int main(){
    int in;
    char S[1000];
    
    for(int i=0;;i++){
        
        in = getchar();
        
        if(in==EOF){
            S[i]='\0';
            break;
        }else{
            S[i]=(char)in;
        }
    }
    
    for(int k=0;;k++){
        
        bool f = false;
        
        for(int i=0;;i++){
            if('a'<=S[i] && S[i]<='y'){
                S[i]++;
            }else if(S[i]=='z'){
                S[i]='a';
            }
            
            if(i>=3){ // && !('a'<=S[i] && S[i]<='z')){
                if(S[i-3]=='t' && S[i-2]=='h' && S[i-1]=='e')
                    f=true;
            }
            if(i>=4){ // && !('a'<=S[i] && S[i]<='z')){
                if(S[i-4]=='t' && S[i-3]=='h')
                    if((S[i-2]=='i' && S[i-1]=='s') || (S[i-2]=='h' && S[i-1]=='t'))
                        f=true;
            }
            
            if(S[i]=='\0') break;
        }
        
        if(f) break;
    }
    
    for(int i=0;S[i]!='\0';i++)
        printf("%c",S[i]);
    
    return 0;
}

C++: #include<iostream>
#include<string>
#include<algorithm>
using namespace std;
int main() {
	string str, the = " the", dis = " this", that = " that";
	int zure, count = 0, i = 0;
	string judge = " ";
	bool bo = false;
	getline(cin, str);
	for (int k = 0; k < 26; k++) {
		for (int j = 0; j < str.size(); j++) {
			zure = str[i] - 't';
			if (str[j] != ' ') {
				judge += str[j] - zure;
			}
			if (str[j] == ' ' || j == str.size() - 1) {
				if (judge == " the" || judge == " this" || judge == " that") {
					bo = true;
					break;
				}
				else {
					i = j+1 ;
					judge = " ";
				}
			}
		}
		if (bo == true) {
			break;
		}
	}
	for (int i = 0; i < str.size(); i++) {
		if (str[i] >= 'a'+abs(zure) && str[i] <= 'z' - abs(zure)) {
			str[i] -= zure;
		}
		else if ((str[i]-abs(zure) < 'a' || str[i]+abs(zure) > 'z') && str[i]!=' ' && str[i]!='.') {
			if (str[i] + zure > 'z') {
				str[i] -= zure; 
			}
			else if (str[i] - zure > 'z') {
				str[i] -= 26 + zure;
			}
			else if (zure < 0) {
				str[i] -= zure;
			}
			else {
				str[i] += 26 - zure;
			}
		}
		cout << str[i];
	}
	cout << endl;
	return 0;
}

C++: 
#include<string>

using namespace std;


int main(){

  string s, strc;

  while(getline(cin,s)){

    for(int j=0;j<26;j++){
      

      if(s.find("the")!=string::npos ||s.find("this")!=string::npos||s.find("that")!=string::npos ){
	cout << s << endl;
      }
      for(int i=0;i<s.size();i++){//size()ツづ債閉カツ篠堋療アツづ個陳キツつウツづーツ陛板つキ
	
	if(s[i]=='z')s[i]='a';
	else if(s[i]>='a'&&s[i]<='z')s[i]++;
      }

    }

  }
  

  return 0;
}

C++: #include<iostream>
#include<cstdio>
#include<cstring>
using namespace std;
char a[53]="abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz";
int main(){
    char str[81];
    while(cin>>str[0]){
        for(int i=1;i<81;i++)str[i]=0;
        for(int i=1;i<80;i++){
            str[i]=getchar();
            if(str[i]==10){
                str[i]=0;
                break;
            }
        }
        int len=strlen(str);

        for(int i=0;i<26;i++){
            char cpy[81];
            strncpy(cpy,str,81);

            for(int j=0;j<len;j++){
                if(str[j]==' ' || str[j]=='.' || str[j]==10)continue;
                cpy[j]=a[cpy[j]-'a'+i];
            }
            bool f=false;
            for(int j=0;j<len-2;j++){
                if(!strncmp(cpy+j,"the",3))f=true;
                if(!strncmp(cpy+j,"this",4))f=true;
                if(!strncmp(cpy+j,"that",4))f=true;
            }
            if(f){
                cout<<cpy<<endl;
                break;
            }
        }
    }
    return 0;


}

C++: #include <iostream>
#include <string>

const char *table = "abcdefghijklmnopqrstuvwxyz";

inline char shift(char c, int n)
{
    return table[(c - 'a' - n) % 26];
}

void shift(std::string &s, int n)
{
    for (unsigned i = 0; i < s.size(); ++i) {
        if (s[i] != ' ' && s[i] != '.') s[i] = shift(s[i], n);
    }
}

int search_number(const std::string &s)
{
    for (unsigned i = 0; i < s.size() - 3; ++i) {
        int n = s[i] - 't';
        if (shift(s[i + 1], n) == 'h') {
            if (shift(s[i + 2], n) == 'e'
                    || (i < s.size() - 3 && shift(s[i + 2], n) == 'i' && shift(s[i + 3], n) == 's')
                    || (i < s.size() - 3 && shift(s[i + 2], n) == 'a' && shift(s[i + 3], n) == 't'))
                return n;
        }
    }
    return s[s.size() - 3] - 't';
}

int main()
{
    std::string s;
    while (getline(std::cin, s)) {
        shift(s, search_number(s));
        std::cout << s << std::endl;
    }
}