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