#include <bits/stdc++.h>
using namespace std;
int main() {
  char x;
  cin >> x;
  string s1 = "qwertyuiopasdfghjkl;zxcvbnm,./";
  string s;
  cin >> s;
  for (int i = 0; i < s.size(); i++) {
    for (int j = 0; j < s1.size(); j++) {
      if (x == 'L') {
        if (s[i] == s1[j]) {
          cout << s1[j + 1];
        }
      } else if (x == 'R') {
        if (s[i] == s1[j]) {
          cout << s1[j - 1];
        }
      }
    }
  }
  return 0;
}
