#include <bits/stdc++.h>
char a[3], b[3], p, q;
int x, y;
int main() {
  gets(a), gets(b);
  x = a[0] - b[0], y = a[1] - b[1];
  if (x < 0)
    p = 'R', x = -x;
  else
    p = 'L';
  if (y < 0)
    q = 'U', y = -y;
  else
    q = 'D';
  for (printf("%d\n", x > y ? x : y); x || y; printf("\n")) {
    if (x) putchar(p), --x;
    if (y) putchar(q), --y;
  }
  return 0;
}
