#include <bits/stdc++.h>
using namespace std;
const int N = 2e5 + 5;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int t = 1;
  while (t--) {
    long long int n, m;
    cin >> n >> m;
    long long int k;
    cin >> k;
    long long int moves = 4LL * n * m - 2 * n - 2 * m;
    if (k > moves) {
      cout << "NO";
      return 0;
    }
    char right = 'R';
    char left = 'L';
    char up = 'U';
    char down = 'D';
    if (m < n) {
      right = 'D';
      left = 'U';
      up = 'L';
      down = 'R';
      swap(n, m);
    }
    cout << "YES\n";
    vector<pair<string, long long int>> v;
    long long int tot = 0;
    bool yes = true;
    if (k >= m - 1) {
      string s = "";
      s += right;
      v.push_back({s, m - 1});
      k -= m - 1;
      tot += 1;
      if (k == 0) yes = false;
    } else {
      string s = "";
      s += right;
      v.push_back({s, k});
      tot += 1;
      k = 0;
      yes = false;
    }
    if (k >= m - 1) {
      string s = "";
      s += left;
      v.push_back({s, m - 1});
      k -= m - 1;
      tot++;
      if (k == 0) yes = false;
    } else if (yes) {
      string s = "";
      s += left;
      v.push_back({s, k});
      tot++;
      k = 0;
      yes = false;
    }
    for (int i = 1; i < n; i++) {
      if (!yes) break;
      if (k >= 1) {
        k -= 1;
        tot += 1;
        string s = "";
        s += down;
        v.push_back({s, 1});
        if (k == 0) yes = false;
      } else
        break;
      if (yes) {
        long long int temp = (m - 1) * 3;
        string s = "";
        s += right;
        s += up;
        s += down;
        long long int f = 0;
        if (k < temp) {
          f = k / 3;
          k %= 3;
          if (f) {
            v.push_back({s, f});
            tot++;
          }
          s = "";
          if (k == 0) break;
          if (k == 1) {
            s += right;
          } else if (k == 2) {
            s += right;
            s += up;
          }
          v.push_back({s, 1});
          tot++;
          k = 0;
          yes = false;
        } else {
          v.push_back({s, m - 1});
          k -= temp;
          tot++;
          if (k == 0) yes = false;
        }
      }
      if (!yes)
        break;
      else {
        string s = "";
        s += left;
        if (k < m - 1) {
          v.push_back({s, k});
          k = 0;
          yes = false;
          tot++;
          break;
        } else {
          v.push_back({s, m - 1});
          k -= m - 1;
          tot++;
        }
      }
    }
    if (k) {
      tot += 1;
      string s = "";
      s += up;
      v.push_back({s, k});
    }
    cout << v.size() << "\n";
    for (auto x : v) {
      cout << x.second << " " << x.first << "\n";
    }
  }
}
