#include <bits/stdc++.h>
using namespace std;
int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long n, m, k;
  cin >> n >> m >> k;
  if (k > 4 * n * m - 2 * n - 2 * m) {
    cout << "NO\n";
    return 0;
  }
  cout << "YES\n";
  vector<pair<long long, char>> op;
  if (m > 1) op.push_back({m - 1, 'R'});
  for (long long i = m; i >= 2; --i) {
    if (n > 1) op.push_back({n - 1, 'D'});
    if (n > 1) op.push_back({n - 1, 'U'});
    op.push_back({1, 'L'});
  }
  for (long long i = 2; i <= n; ++i) {
    op.push_back({1, 'D'});
    if (m > 1) op.push_back({m - 1, 'R'});
    if (m > 1) op.push_back({m - 1, 'L'});
  }
  if (n > 1) op.push_back({n - 1, 'U'});
  long long step = 0, sz = 0;
  for (auto &[S, D] : op) {
    if (step == k) {
      S = 0;
      break;
    }
    if (step + S < k)
      step += S;
    else
      S = k - step, step = k;
    ++sz;
  }
  cout << sz << "\n";
  for (auto [S, D] : op) {
    if (S == 0) break;
    cout << S << " " << D << "\n";
  }
  return 0;
}
