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