#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c, i, j, k, t, e, f;
  cin >> a >> b >> c;
  vector<pair<int, int> > v1, v2;
  for (i = 0; i < c; i++) {
    cin >> e >> f;
    v1.push_back(make_pair(e, f));
  }
  for (i = 0; i < c; i++) {
    cin >> e >> f;
    v2.push_back(make_pair(e, f));
  }
  cout << a - 1 + b - 1 + a - 1 + (a) * (b - 1) << "\n";
  for (i = 0; i < a - 1; i++) {
    cout << "U";
  }
  for (i = 0; i < b - 1; i++) {
    cout << "L";
  }
  for (i = 0; i < a; i++) {
    if (i != 0) {
      cout << "D";
    }
    for (j = 0; j < b - 1; j++) {
      if (i % 2 == 0) {
        cout << "R";
      } else {
        cout << "L";
      }
    }
  }
}
