#include <bits/stdc++.h>
const long long MOD = 1000000007;
const long long MAX = 1000010;
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  char a, b;
  cin >> a >> b;
  char c, d;
  cin >> c >> d;
  vector<string> moves;
  while (a != c or b != d) {
    if (a != c and b != d) {
      if (a < c) {
        if (b > d) {
          moves.push_back("RD");
          b--;
        } else if (b < d) {
          moves.push_back("RU");
          b++;
        }
        a++;
      } else {
        if (b > d) {
          moves.push_back("LD");
          b--;
        } else if (b < d) {
          moves.push_back("LU");
          b++;
        }
        a--;
      }
    } else if (a == c) {
      if (b > d) {
        moves.push_back("D");
        b--;
      } else if (b < d) {
        moves.push_back("U");
        b++;
      }
    } else if (b == d) {
      if (a > c) {
        moves.push_back("L");
        a--;
      } else if (a < c) {
        moves.push_back("R");
        a++;
      }
    }
  }
  cout << moves.size() << endl;
  for (auto s : moves) {
    cout << s << endl;
  }
  return 0;
}
