#include <bits/stdc++.h>
using namespace std;
int main() {
  vector<string> v;
  v.push_back("qwertyuiop");
  v.push_back("asdfghjkl;");
  v.push_back("zxcvbnm,./");
  string dir, err, output;
  cin >> dir;
  cin >> err;
  int s = err.size();
  if (dir == "R") {
    for (int i = 0; i < s; i++) {
      char c = err[i];
      int s2 = v[0].size();
      for (int x = 0; x < 3; x++) {
        for (int j = 0; j < s2; j++) {
          if (v[x][j] == c) {
            output += v[x][j - 1];
            break;
          }
        }
      }
    }
  } else {
    for (int i = 0; i < s; i++) {
      char c = err[i];
      int s2 = v[0].size();
      for (int x = 0; x < 3; x++) {
        for (int j = 0; j < s2; j++) {
          if (v[x][j] == c) {
            output += v[x][j + 1];
            break;
          }
        }
      }
    }
  }
  cout << output << endl;
  return 0;
}
