//加密请先输入"+",解密请先输入"!"
#include<stdio.h>
void jiami();
void jiemi();
void main()
{
char c=getchar();
if(c=='!'){
jiemi();
printf("\n");}
else if(c=='+'){
jiami();
printf("\n");}
else
printf("加密要先输入“+”,解密要先输入“!”\n");
}
void jiami()
{
int c;
while((c=getchar())!='\n')
switch(c){
case 'a':printf("q");break;
case 'b':printf("w");break;
case 'c':printf("e");break;
case 'd':printf("r");break;
case 'e':printf("t");break;
case 'f':printf("y");break;
case 'g':printf("u");break;
case 'h':printf("i");break;
case 'i':printf("o");break;
case 'j':printf("p");break;
case 'k':printf("a");break;
case 'l':printf("s");break;
case 'm':printf("d");break;
case 'n':printf("f");break;
case 'o':printf("g");break;
case 'p':printf("h");break;
case 'q':printf("j");break;
case 'r':printf("k");break;
case 's':printf("l");break;
case 't':printf("z");break;
case 'u':printf("x");break;
case 'v':printf("c");break;
case 'w':printf("v");break;
case 'x':printf("b");break;
case 'y':printf("n");break;
case 'z':printf("m");break;
case ' ':printf(" ");break;
}}
void jiemi()
{
int c;
while((c=getchar())!='\n')
switch(c){
case 'a':printf("k");break;
case 'b':printf("x");break;
case 'c':printf("v");break;
case 'd':printf("m");break;
case 'e':printf("c");break;
case 'f':printf("n");break;
case 'g':printf("o");break;
case 'h':printf("p");break;
case 'i':printf("h");break;
case 'j':printf("q");break;
case 'k':printf("r");break;
case 'l':printf("s");break;
case 'm':printf("z");break;
case 'n':printf("y");break;
case 'o':printf("i");break;
case 'p':printf("j");break;
case 'q':printf("a");break;
case 'r':printf("d");break;
case 's':printf("l");break;
case 't':printf("e");break;
case 'u':printf("g");break;
case 'v':printf("w");break;
case 'w':printf("b");break;
case 'x':printf("u");break;
case 'y':printf("f");break;
case 'z':printf("t");break;
case ' ':printf(" ");break;
}}