#include <bits/stdc++.h>
using namespace std;
map<char, string> ma;
int main() {
  ma['U'] = "U";
  ma['R'] = "R";
  ma['L'] = "L";
  ma['D'] = "D";
  int n, m, k;
  cin >> n >> m >> k;
  if (k > 4 * n * m - 2 * n - 2 * m) {
    cout << "NO";
    return 0;
  }
  cout << "YES" << endl;
  vector<pair<int, string> > ans;
  int uk = 1;
  while (uk < m) {
    if (uk % 2 == 1) {
      if (n > 1) ans.push_back({n - 1, "RLD"});
      ans.push_back({1, "R"});
    } else {
      if (n > 1) ans.push_back({n - 1, "RLU"});
      ans.push_back({1, "R"});
    }
    ++uk;
  }
  if (m % 2 == 1) {
    if (n > 1) ans.push_back({n - 1, "D"});
  } else {
    if (n > 1) ans.push_back({n - 1, "U"});
  }
  while (uk > 1) {
    if (uk % 2 == 0) {
      if (n > 1) ans.push_back({n - 1, "D"});
      ans.push_back({1, "L"});
    } else {
      if (n > 1) ans.push_back({n - 1, "U"});
      ans.push_back({1, "L"});
    }
    --uk;
  }
  if (n > 1) ans.push_back({n - 1, "U"});
  vector<pair<int, string> > new_ans;
  for (int i = 0; i < ans.size(); ++i) {
    if (k <= ans[i].first * ans[i].second.size()) {
      pair<int, string> now = {0, ans[i].second};
      for (int j = 0; j < ans[i].first; ++j) {
        if (k <= ans[i].second.size()) {
          if (now.first != 0) new_ans.push_back(now);
          for (int r = 0; r < ans[i].second.size(); ++r) {
            if (k <= 1) {
              k -= 1;
              new_ans.push_back({1, ma[(ans[i].second)[r]]});
              break;
            } else {
              k -= 1;
              new_ans.push_back({1, ma[(ans[i].second)[r]]});
            }
          }
          break;
        } else {
          k -= ans[i].second.size();
          now.first++;
        }
      }
      break;
    } else {
      k -= ans[i].first * ans[i].second.size();
      new_ans.push_back(ans[i]);
    }
  }
  cout << new_ans.size() << endl;
  for (int i = 0; i < new_ans.size(); ++i) {
    cout << new_ans[i].first << ' ' << new_ans[i].second << endl;
  }
  return 0;
}
