#include<iostream>
#include<vector>
#include<string>
using namespace std;
int main(){
	int res=0;
	vector<string> buf;
	string str;
	while((cin>>str)!=NULL)
		buf.push_back(str);
	for(int ptr=0;ptr<buf.size();++ptr){
		if(res!=0) break;
		if(buf[ptr].length()>2)
		if(buf[ptr][0]-buf[ptr][1]=='t'-'h'){
			int dif='t'-buf[ptr][0];
			string tmp;
			for(int i=0;i<buf[ptr].length();++i)
				tmp += (buf[ptr][i]=='.'?'.':(buf[ptr][i]-'a'+dif)%26+'a');
			if(tmp=="the" or tmp=="this" or tmp=="that" or tmp=="this." or tmp=="that."){
				res = dif;
				break;
			}
		}
		cout<<1;
	}
	if(res!=0){
		for(int ptr=0;ptr<buf.size();++ptr){
			string tmp;
			for(int i=0;i<buf[ptr].length();++i)
				tmp += ((buf[ptr][i]=='.') ? '.' : (buf[ptr][i]-'a'+res)%26+'a');
			cout<<tmp<<(ptr==buf.size()-1?"":" ");
		}
	}
	if(res==0) cout<<"-1";
	cout<<endl;
	return 0;
}