#include <bits/stdc++.h>
using namespace std;
const int N = 200005;
int n, m, k, x[N], y[N];
int mx, my;
int main() {
  scanf("%d%d%d", &n, &m, &k);
  for (int i = 1; i <= k; i++) scanf("%d%d", &x[i], &y[i]);
  for (int i = 1; i <= k; i++) scanf("%d%d", &x[i + k], &y[i + k]);
  for (int i = 1; i <= k; i++) mx = max(mx, x[i]), my = max(my, y[i]);
  printf("%d\n", mx + my - 2 + n * m - 1);
  for (int i = 1; i < mx; i++) printf("U");
  for (int i = 1; i < my; i++) printf("L");
  for (int i = 1; i <= n; i++) {
    if (i % 2 == 1)
      for (int j = 1; j < m; j++) printf("R");
    else
      for (int j = 1; j < m; j++) printf("L");
    if (i < n) printf("D");
  }
  printf("\n");
}
