#include <bits/stdc++.h>
using namespace std;
string a[] = {"qwertyuiop", "asdfghjkl;", "zxcvbnm,./"};
int main() {
  char ch;
  cin >> ch;
  string s;
  cin >> s;
  for (int i = 0; i < s.length(); i++) {
    for (int j = 0; j < 3; j++)
      for (int g = 0; g < a[j].length(); g++)
        if (a[j][g] == s[i]) {
          if (ch == 'R')
            cout << a[j][g - 1];
          else
            cout << a[j][g + 1];
          break;
        }
  }
  cin >> ch;
  return 0;
}
