#include <bits/stdc++.h>
using namespace std;
pair<int, int> findre(string s[3], char ch) {
  pair<int, int> ans;
  for (int i = 0; i < 3; i++) {
    for (int j = 0; j < 10; j++) {
      if (s[i][j] == ch) {
        ans.first = i;
        ans.second = j;
      }
    }
  }
  return ans;
}
int main() {
  string s[] = {"qwertyuiop", "asdfghjkl;", "zxcvbnm,./"};
  char ch;
  cin >> ch;
  int m;
  if (ch == 'R')
    m = -1;
  else
    m = 1;
  string q;
  cin >> q;
  pair<int, int> temp;
  for (int i = 0; i < q.length(); i++) {
    temp = findre(s, q[i]);
    cout << s[temp.first][temp.second + m];
  }
  return 0;
}
