#include <bits/stdc++.h>
using namespace std;
const long long INF = 0x3f3f3f3f;
const long long dir[4][2] = {-1, 0, 1, 0, 0, -1, 0, 1};
const double PI = acos(-1.0);
const double eps = 1e-10;
const long long M = 1e9 + 7;
const long long N = 1e5 + 5;
long long b[250][250], e[250][250];
signed main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long n, m, k, x, y;
  cin >> n >> m >> k;
  for (long long i = 1; i <= (2 * k); i++) {
    cin >> x >> y;
  }
  long long ans = 2 * m - 2 + n - 1 + m * (n - 1);
  cout << ans << '\n';
  for (long long i = 1; i < m; i++) cout << "L";
  for (long long i = 1; i < n; i++) cout << "U";
  for (long long i = 1; i < n; i++) {
    for (long long j = 1; j < m; j++) {
      if (i & 1)
        cout << "R";
      else
        cout << "L";
      ans++;
    }
    cout << "D";
    ans++;
  }
  for (long long j = 1; j < m; j++) {
    if (n & 1)
      cout << "R";
    else
      cout << "L";
  }
  return 0;
}
