#include <bits/stdc++.h>
using namespace std;
int ans, n, m, k, a[3001];
string b[3001];
int main() {
  scanf("%d%d%d", &n, &m, &k);
  int tot = 4 * n * m - 2 * n - m * 2;
  if (k > tot) {
    printf("NO");
    return 0;
  }
  if (n == 1 && m == 1) {
    printf("NO");
    return 0;
  }
  if (n == 1) {
    if (k > 2 * m - 2) {
      printf("NO");
      return 0;
    }
    printf("YES\n");
    if (k <= m - 1)
      printf("1\n%d %c\n", k, 'R');
    else {
      printf("2\n%d %c\n", m - 1, 'R');
      printf("%d %c", k - m + 1, 'L');
    }
    return 0;
  }
  if (m == 1) {
    if (k > 2 * n - 2) {
      printf("NO");
      return 0;
    }
    printf("YES\n");
    if (k <= n - 1)
      printf("1\n%d %c\n", k, 'D');
    else {
      printf("2\n%d %c\n", n - 1, 'D');
      printf("%d %c", k - n + 1, 'U');
    }
    return 0;
  }
  printf("YES\n");
  bool flag = false;
  int x;
  if (k > 4 * n * m - 2 * n - m * 2 - n + 1)
    flag = true, x = k - (4 * n * m - 2 * n - m * 2 - n + 1);
  if (k <= m - 1) {
    a[++ans] = k;
    b[ans] = "R";
  } else if (k <= 2 * m - 2) {
    a[++ans] = m - 1;
    b[ans] = "R";
    a[++ans] = k - m + 1;
    b[ans] = "L";
  } else {
    k -= 2 * m - 2;
    a[++ans] = m - 1;
    b[ans] = "R";
    a[++ans] = m - 1;
    b[ans] = "L";
    while (!flag && k >= 4 * m - 3) {
      a[++ans] = 1;
      b[ans] = "D";
      a[++ans] = m - 1;
      b[ans] = "R";
      a[++ans] = m - 1;
      b[ans] = "UDL";
      k -= 4 * m - 3;
    }
    while (flag && k >= 4 * m - 3 + x) {
      a[++ans] = 1;
      b[ans] = "D";
      a[++ans] = m - 1;
      b[ans] = "R";
      a[++ans] = m - 1;
      b[ans] = "UDL";
      k -= 4 * m - 3;
    }
    if (k) {
      if (flag)
        a[++ans] = x, b[ans] = "U";
      else {
        if (k <= 1)
          a[++ans] = 1, b[ans] = "D";
        else if (k <= m) {
          a[++ans] = 1;
          b[ans] = "D";
          a[++ans] = k - 1;
          b[ans] = "R";
        } else {
          a[++ans] = 1;
          b[ans] = "D";
          a[++ans] = m - 1;
          b[ans] = "R";
          k -= m;
          if (k >= 3) a[++ans] = k / 3, b[ans] = "UDL", k -= a[ans] * 3;
          if (k == 1) a[++ans] = 1, b[ans] = "U";
          if (k == 2) a[++ans] = 1, b[ans] = "UD";
        }
      }
    }
  }
  printf("%d\n", ans);
  for (int i = 1; i <= ans; i++) printf("%d ", a[i]), cout << b[i] << endl;
  return 0;
}
