#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int n, m, k;
  cin >> n >> m >> k;
  cout << ((2 * n * m) - 2) << endl;
  string f = "";
  int flag = 0;
  for (int i = 0; i < m; i++) {
    if (flag == 0) {
      for (int j = 0; j < n - 1; j++) {
        f += "D";
      }
      if (i < m - 1) {
        f += "R";
      }
      flag = 1;
    } else {
      for (int j = 0; j < n - 1; j++) {
        f += "U";
      }
      if (i < m - 1) {
        f += "R";
      }
      flag = 0;
    }
  }
  int len = f.length();
  for (int i = len - 1; i >= 0; i--) {
    if (f[i] == 'D') {
      f += "U";
    }
    if (f[i] == 'U') {
      f += "D";
    }
    if (f[i] == 'L') {
      f += "R";
    }
    if (f[i] == 'R') {
      f += "L";
    }
  }
  cout << f << endl;
}
