#include<stdio.h>
#include<string.h>
int main()
{
int i;
char en_s[]="START";
char en_e[]="END";
char end[]="ENDOFINPUT";
char a[1000];
for(;;)
{
gets(a);
if(strcmp(en_s,a)==0)
continue;
if(strcmp(en_e,a)==0)
continue;
if(strcmp(end,a)==0)
break;
for(i=0;a[i]!=' ';i++)
{
if(a[i]>='A'&&a[i]<='E')
a[i]=a[i]+21;
else if(a[i]>='F'&&a[i]<='Z')
a[i]=a[i]-5;
}
puts(a);
}
return 0;
}