#include <bits/stdc++.h>
using namespace std;
using namespace std::chrono;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  auto start = high_resolution_clock::now();
  int n, m, k;
  cin >> n >> m >> k;
  int l = 2 * k;
  while (l--) {
    int x, y;
    cin >> x >> y;
  }
  if (m == 1) {
    cout << 2 * n << endl;
    for (int i = 1; i <= n; i++) {
      cout << "U";
    }
    for (int i = 1; i <= n; i++) {
      cout << "D";
    }
  } else if (n == 1) {
    cout << 2 * m << endl;
    for (int i = 1; i <= m; i++) {
      cout << "R";
    }
    for (int i = 1; i <= m; i++) {
      cout << "L";
    }
  } else {
    cout << (n + m) + m * n << endl;
    for (int i = 1; i <= n; i++) {
      cout << "U";
    }
    for (int i = 1; i <= m; i++) {
      cout << "L";
    }
    for (int i = 1; i <= n; i++) {
      for (int ct = 1; ct <= m; ct++) {
        if (ct == m) {
          cout << "D";
          ct++;
          continue;
        }
        if (i % 2)
          cout << "R";
        else
          cout << "L";
      }
    }
  }
  auto stop = high_resolution_clock::now();
  auto duration = duration_cast<microseconds>(stop - start);
}
