#include <bits/stdc++.h>
using namespace std;
int main() {
  int xDiff = 0, yDiff = 0;
  int numMoves = 0;
  string start, end;
  string listOfMoves = "";
  cin >> start >> end;
  xDiff = end[0] - start[0];
  yDiff = end[1] - start[1];
  while (yDiff != 0 || xDiff != 0) {
    if (xDiff > 0) {
      xDiff--;
      listOfMoves += "R";
    } else if (xDiff < 0) {
      xDiff++;
      listOfMoves += "L";
    }
    if (yDiff > 0) {
      yDiff--;
      listOfMoves += "U";
    } else if (yDiff < 0) {
      yDiff++;
      listOfMoves += "D";
    }
    listOfMoves += "\n";
    numMoves++;
  }
  cout << numMoves << endl;
  cout << listOfMoves << endl;
  return 0;
}
