#include <bits/stdc++.h>
using namespace std;
const long long INF = 1e18 + 7;
const long long N = 1e5 + 7;
const long long MOD = 1e9 + 7;
const double Pi = 3.14159265358979323846;
signed main() {
  {
    ios_base::sync_with_stdio(0);
    cin.tie(0);
    cout << fixed << setprecision(20);
    cerr << fixed << setprecision(11);
  };
  long long n, m, k;
  cin >> n >> m >> k;
  long long x, y;
  for (long long i = 0; i < k; i++) cin >> x >> y;
  for (long long i = 0; i < k; i++) cin >> x >> y;
  cout << n * m + n + m - 3 << '\n';
  for (long long i = 0; i < n - 1; i++) cout << 'U';
  for (long long i = 0; i < m - 1; i++) cout << 'L';
  for (long long i = 0; i < n; i++) {
    if (i != 0) cout << 'D';
    if (i % 2 == 0) {
      for (long long j = 0; j < m - 1; j++) cout << 'R';
    } else {
      for (long long j = 0; j < m - 1; j++) cout << 'L';
    }
  }
  return 0;
}
