#include <bits/stdc++.h>
using namespace std;
signed main() {
  ios_base::sync_with_stdio();
  cin.tie(0);
  cout.tie(0);
  ;
  long long n, m, k;
  cin >> n >> m >> k;
  long long lim = 4 * m * n - 2 * n - 2 * m;
  if (lim < k) {
    cout << "NO" << '\n';
    return 0;
  }
  long long ans = 0;
  vector<int> ans1;
  vector<string> ans2;
  cout << "YES" << '\n';
  int flag = 0;
  for (int i = 0; i < n; i++) {
    if (k == 0) break;
    if (k >= m - 1) {
      if (flag) {
        ans1.push_back(m - 1);
        ans2.push_back("L");
        flag = 0;
        ans++;
      } else {
        ans1.push_back(m - 1);
        ans2.push_back("R");
        flag = 1;
        ans++;
      }
      k = k + 1 - m;
      if (k >= 1 && i < n - 1) {
        ans1.push_back(1);
        ans2.push_back("D");
        k--;
        ans++;
      }
    } else {
      if (flag) {
        ans1.push_back(k);
        ans2.push_back("L");
        flag = 0;
        ans++;
      } else {
        ans1.push_back(k);
        ans2.push_back("R");
        flag = 1;
        ans++;
      }
      k = 0;
    }
  }
  for (int i = 1; i < n; i++) {
    if (k == 0) break;
    if (k >= 3 * (m - 1)) {
      if (flag) {
        ans1.push_back(m - 1);
        ans2.push_back("UDL");
        flag = 0;
        ans++;
      } else {
        ans1.push_back(m - 1);
        ans2.push_back("UDR");
        flag = 1;
        ans++;
      }
      k = k - 3 * (m - 1);
      if (k >= 1) {
        ans1.push_back(1);
        ans2.push_back("U");
        k -= 1;
        ans++;
      }
    } else {
      long long x = k / 3;
      long long y = k % 3;
      if (flag) {
        ans1.push_back(x);
        ans2.push_back("UDL");
        flag = 0;
        ans++;
      } else {
        ans1.push_back(x);
        ans2.push_back("UDR");
        flag = 1;
        ans++;
      }
      if (y == 1) {
        ans++;
        ans1.push_back(1);
        ans2.push_back("U");
      }
      if (y == 2) {
        ans++;
        ans1.push_back(1);
        ans2.push_back("UD");
      }
      k = 0;
    }
  }
  if (k > 0) {
    ans1.push_back(k);
    ans2.push_back("L");
    ans++;
  }
  for (int i = 0; i < ans1.size(); i++) {
    if (ans1[i] == 0) ans--;
  }
  cout << ans << '\n';
  for (int i = 0; i < ans1.size(); i++) {
    if (ans1[i] != 0) cout << ans1[i] << " " << ans2[i] << '\n';
  }
  return 0;
}
