#include <bits/stdc++.h>
int main() {
  int n, temp, count, i, len, len1, j;
  char c, a[200], b[40];
  strcpy(b, "qwertyuiopasdfghjkl;zxcvbnm,./");
  while (~scanf("%c", &c)) {
    getchar();
    gets(a);
    len = strlen(a);
    len1 = strlen(b);
    if (c == 'R')
      temp = -1;
    else
      temp = 1;
    for (i = 0; i < len; i++) {
      for (j = 0; j < len1; j++) {
        if (a[i] == b[j]) printf("%c", b[j + temp]);
      }
    }
    puts("");
  }
  return 0;
}
