#include <bits/stdc++.h>
using namespace std;
char board[3][11] = {"qwertyuiop", "asdfghjkl;", "zxcvbnm,./"};
int mx[105];
int my[105];
char sq[105];
int main() {
  char dir;
  cin >> dir >> sq;
  int n = strlen(sq);
  int c = 0;
  for (int k = 0; k < n; k++)
    for (int i = 0; i < 3; i++)
      for (int j = 0; j < 10; j++)
        if (sq[k] == board[i][j]) {
          my[c] = j;
          mx[c] = i;
          c++;
        }
  if (dir == 'R')
    for (int i = 0; i < c; i++) cout << board[mx[i]][my[i] - 1];
  else if (dir == 'L')
    for (int i = 0; i < c; i++) cout << board[mx[i]][my[i] + 1];
  cout << endl;
}
