#include <bits/stdc++.h>
using namespace std;
const int MAXN = 1e5 + 5;
int a[MAXN];
int b[MAXN];
int c[MAXN];
int pos[MAXN];
signed main() {
  int n;
  int m;
  int k;
  cin >> n >> m >> k;
  int sum = m - 1 + n - 1 + n * (m - 1) + n - 1;
  cout << sum << endl;
  for (int y = 1; y <= n - 1; y++) cout << "D";
  for (int y = 1; y <= m - 1; y++) cout << "L";
  int j;
  for (j = 1; j <= n - 1; j++) {
    if (j % 2 == 1)
      for (int i = 1; i <= m - 1; i++) cout << 'R';
    else
      for (int i = 1; i <= m - 1; i++) cout << 'L';
    cout << "U";
  }
  if (j % 2 == 1)
    for (int i = 1; i <= m - 1; i++) cout << 'R';
  else
    for (int y = 1; y <= m - 1; y++) cout << 'L';
  return 0;
}
