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