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 <iostream>
#include <vector>
#include <string>
#include <stack>
#include <queue>
#include <deque>
#include <set>
#include <map>
#include <algorithm>	// require sort next_permutation count __gcd reverse etc.
#include <cstdlib>	// require abs exit atof atoi 
#include <cstdio>		// require scanf printf
#include <functional>
#include <numeric>	// require accumulate
#include <cmath>		// require fabs
#include <climits>
#include <limits>
#include <cfloat>
#include <iomanip>	// require setw
#include <sstream>	// require stringstream 
#include <cstring>	// require memset
#include <cctype>		// require tolower, toupper
#include <fstream>	// require freopen
#include <ctime>		// require srand
#define rep(i,n) for(int i=0;i<(n);i++)
#define ALL(A) A.begin(), A.end()

using namespace std;

typedef long long ll;
typedef pair<int, int> P;

const string w[] = { "the", "this", "that" };

string decoded_letter (string s, int m )
{
	int n = s.length();
	rep (i, n ){
		if (s[i] == ' ' || s[i] == ',' || s[i] == '.' ) continue;
		s[i] = (char)(((int)(s[i] - 'a') + m ) % 26 + 'a');
	} // end rep

	return s; 
}

bool is_include (string s )
{
	int n = s.length();
	rep (i, n ){
		if (s[i] == ',' || s[i] == '.' ) s[i] = ' ';
	} // end rep

	stringstream ss (s );
	string t = "";
	while (ss >> t ){
		rep (i, sizeof (w )/sizeof (w[0] ) ){
			if (t == w[i] ){
				return true;
			} // end if
		} // end rep
	} // end while

	return false;
}

int main()
{
//	cut here before submit 
//	freopen ("testcase.CC", "r", stdin );
	string str = "";
	while (getline (cin, str ) ){
		string decode = "";
		rep (i, 26 ){	// secret number
			decode = decoded_letter (str, i );
			if (is_include (decode ) ){
				break;
			} // end if
		} // end rep
		cout << decode << endl;		
	} // end loop
		
	return 0;
}

C++: #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#pragma warning(disable:4996)

bool Check(char* Str);

int main()
{
	int  nCnt = 0;
	char PhraseIn[80];
	char PhraseOut[80] = "\0";
	int  nSlide = 1;

	gets(PhraseIn);

	while (1)
	{
		for (nCnt = 0; PhraseIn[nCnt] != '\0'; nCnt++)
		{
			if (PhraseIn[nCnt] == ' ' || PhraseIn[nCnt] == '.' || PhraseIn[nCnt] == '\n')
			{
				PhraseOut[nCnt] = PhraseIn[nCnt];
				continue;
			}

			PhraseOut[nCnt] = PhraseIn[nCnt] - nSlide;

			if (PhraseOut[nCnt] > 122)
				PhraseOut[nCnt] = 97 + (nSlide-1);

			if (PhraseOut[nCnt] < 97)
				PhraseOut[nCnt] = 122 - (nSlide - 1);
		}

		if (Check(PhraseOut))
			break;
		else
		{
			nSlide++;
			if (nSlide >= 26)
				break;
		}
	}

	if (nSlide >= 26)
		printf("This Not Found");
	else
		printf("%s", PhraseOut);

	return 0;
}

bool Check(char* Str)
{
	int nCnt = 0;
	int nCnt2 = 0;

	while (Str[nCnt] != '\0')
	{
		char Work[80] = "\0";
		nCnt2 = 0;
		while (1)
		{
			if (Str[nCnt] == ' ' || Str[nCnt] == '.' || Str[nCnt] == '\n' || Str[nCnt] == '\0')
			{
				nCnt++;
				break;
			}

			Work[nCnt2] = Str[nCnt];
			nCnt++;
			nCnt2++;
		}

		if (strcmp(Work, "this") == 0 || strcmp(Work, "the") == 0 || strcmp(Work, "that") == 0)
			return true;
	}

	return false;
}

C++: #include<stdio.h>
#include<string.h>


void Roll(char ch[], int times) {
	int cnt = 0;
	while (ch[cnt] != 0) {
		if (96 < ch[cnt] && 123 > ch[cnt])
			ch[cnt] = (ch[cnt] - 97 + times) % 26 + 97;
		cnt++;
	}
}

int main() {
	char inp[100]; char buff[80];

	int pos = 0, bpos = 0;

	while (1) {
		if (gets_s(inp, 100) == NULL)break;
		while (1) {
			if (96 < inp[pos] && 123 > inp[pos]) {
				buff[bpos] = inp[pos];
				bpos++; pos++;
			}
			else {
				buff[bpos] = '\0';
				if (strlen(buff) != 3 && strlen(buff) != 4) {
					bpos = 0;
					continue;
				}
				Roll(buff, 116 - inp[0]);
				if (strcmp(buff, "this") == 0 || strcmp(buff, "that") == 0 || strcmp(buff, "the") == 0) {
					Roll(inp, 116 - inp[0]);
					break;
				}
				else {
					bpos = 0;
					continue;
				}

			}
		}
		puts(inp);
	}
	return 0;
}

C++: #include <iostream>
#include <stdio.h>
#include <string.h>
#include <string>
#include <algorithm>
#include <vector>

using namespace std;

void q17() {
	vector<string> hints;
	hints.push_back("the");
	hints.push_back("this");
	hints.push_back("that");

	vector< vector<string> > shiftHints;
	for (int i = 0; i < 26; i++) {
		vector<string> iShiftHints;
		for (int j = 0; j < hints.size(); j++) {
			string tmp = "";
			for (int k = 0; k < hints[j].length(); k++) {
				char z = ((hints[j][k] - 'a' + i) % 26) + 'a';
				tmp += ((hints[j][k] - 'a' + i) % 26) + 'a';
			}
			iShiftHints.push_back(tmp);
		}
		shiftHints.push_back(iShiftHints);
	}

	string str;
	for (; getline(cin, str);) {
		int s;
		bool flag = false;
		for (s = 0; s < 26; s++) {
			for (int i = 0; i < hints.size(); i++) {
				if (str.find(shiftHints[s][i]) != -1) {
					flag = true;
				}
			}
			if (flag) break;
		}

		string ans = "";
		for (int i = 0; i < str.length(); i++) {
			if ('a' <= str[i] && str[i] <= 'z') {
				ans += (str[i] - 'a' - s) % 26 + 'a';
			}
			else {
				ans += str[i];
			}
		}
		cout << ans << endl;
		break;
	}
}

int main() {
	q17();
	return 0;
}

C++: #include <iostream>
#include <cstdio>
#include <stdio.h>
#include <string>

using namespace std;
static const int MAXV = 81;

bool hantei(char* data);
void irekae(char* data);

int main() {
  while(!feof(stdin)) {
    char data[MAXV];
    if(fgets(data, sizeof(data), stdin)==NULL) break;
    while(!hantei(data))
      irekae(data);
    printf("%s", data);
  }
}

bool hantei(char* data) {
  if(strstr(data, "the")) return 1;
  if(strstr(data, "this")) return 1;
  if(strstr(data, "that")) return 1;
  return 0;
}

void irekae(char* data) {
  for(int i=0;data[i]!=0;i++) {
    if(data[i]>='a' && data[i]<='z') {
      if(data[i]=='z')data[i]='a';
      else data[i]++;
    }
  }
}

C++: #include <bits/stdc++.h>
#include <vector>
using namespace std;
string str;	
int a, b, c, d;
int main(){
	while(getline(cin, str)){
		a = str.length();
		for(int i = 0; i < a; i++){
			if(str[i] < 97 || str[i] > 122){
				cout << str[i];
			}
			else {
				b = (int)str[i];
				b = b - 4;
				if(b < 97)
					b = b + 26;
				cout << (char)b;
			}
		}
		cout << endl;
	}
	return 0;
}

C++: #include <iostream>
#include <cstdio>
#include <vector>
#include <list>
#include <algorithm>
#include <cmath>
#include <stack>
#include <set>
using namespace std;

#define REP(i,n) for(int (i)=0; (i)<(n); (i)++)
#define FOR(i,a,b) for(int (i)=(a); (i)<(b); (i)++)
#define PUSH(n,v) for(int i=0; i<(n); i++) {int j; cin >> j; v.push_back(j);}
#define ALL(v) v.begin(), v.end()

void rot1(string &s) {
    string t = "";
    REP(i,s.size()) {
        if (s[i] > 'a' && s[i] < 'z') {
            if (s[i] == 'a') t += "z";
            else t += s[i] - 1;
        }else {
            t += s[i];
        }
    }
    s = t;
}

int main() {
    string s;
    while(getline(cin, s)) {
        while(s.find("the") == string::npos && s.find("this") == string::npos && s.find("that") == string::npos) {
            rot1(s);
        }
        cout << s << endl;
    }
    return 0;
}