#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, k;
  cin >> n >> m >> k;
  for (int i = 0; i < 2 * k; i++) {
    int a, b;
    cin >> a >> b;
  }
  if (n == 1) {
    cout << 2 * (m - 1) << "\n";
    for (int i = 1; i < m; i++) {
      cout << "L";
    }
    for (int i = 1; i < m; i++) {
      cout << "R";
    }
  } else if (m == 1) {
    cout << 2 * (n - 1) << "\n";
    for (int i = 1; i < n; i++) {
      cout << "U";
    }
    for (int i = 1; i < n; i++) {
      cout << "D";
    }
  } else {
    cout << n + m + (n * m) - 3 << "\n";
    for (int i = 1; i < m; i++) {
      cout << "L";
    }
    for (int i = 1; i < n; i++) {
      cout << "U";
    }
    for (int i = 1; i <= m; i++) {
      if (i % 2) {
        for (int i = 1; i < n; i++) {
          cout << "D";
        }
        if (i != m) {
          cout << "R";
        }
      } else {
        for (int i = 1; i < n; i++) {
          cout << "U";
        }
        if (i != m) {
          cout << "R";
        }
      }
    }
  }
}
