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