#include <bits/stdc++.h>
using namespace std;
long long n, m, k;
long long now, p;
vector<pair<long long, string> > ans;
void print() {
  assert(now == k);
  cout << "YES\n";
  cout << ans.size() << "\n";
  for (pair<long long, string> i : ans) {
    cout << i.first << " " << i.second << "\n";
  }
}
signed main() {
  ios_base::sync_with_stdio(0), cin.tie(0);
  cin >> n >> m >> k;
  if (k > 4 * n * m - 2 * n - 2 * m) {
    cout << "NO\n";
    return 0;
  }
  p = 1;
  while (now + 2 * (n - 1) + 1 <= k && p < m) {
    if (n - 1) ans.push_back(pair<long long, string>(n - 1, "D"));
    if (n - 1) ans.push_back(pair<long long, string>(n - 1, "U"));
    ans.push_back(pair<long long, string>(1, "R"));
    now += 2 * (n - 1) + 1;
    p++;
  }
  if (now == k) {
    print();
    return 0;
  }
  if (p != m) {
    if (n - 1 && now + (n - 1) <= k) {
      ans.push_back(pair<long long, string>(n - 1, "D"));
      now += (n - 1);
    } else if (n - 1 && now < k) {
      ans.push_back(pair<long long, string>(k - now, "D"));
      now += (k - now);
    }
    if (now == k) {
      print();
      return 0;
    }
    if (n - 1 && now + (n - 1) <= k) {
      ans.push_back(pair<long long, string>(n - 1, "U"));
      now += (n - 1);
    } else if (n - 1 && now < k) {
      ans.push_back(pair<long long, string>(k - now, "U"));
      now += (k - now);
    }
    if (now == k) {
      print();
      return 0;
    }
  }
  if (n - 1 && now + (n - 1) <= k) {
    ans.push_back(pair<long long, string>(n - 1, "D"));
    now += (n - 1);
  } else if (n - 1 && now < k) {
    ans.push_back(pair<long long, string>(k - now, "D"));
    now += (k - now);
  }
  if (now == k) {
    print();
    return 0;
  }
  p = n;
  while (now + 2 * (m - 1) + 1 <= k && p > 1) {
    if (m - 1) ans.push_back(pair<long long, string>(m - 1, "L"));
    if (m - 1) ans.push_back(pair<long long, string>(m - 1, "R"));
    ans.push_back(pair<long long, string>(1, "U"));
    now += 2 * (m - 1) + 1;
    p--;
  }
  if (now == k) {
    print();
    return 0;
  }
  if (p != 1) {
    if (m - 1 && now + (m - 1) <= k) {
      ans.push_back(pair<long long, string>(m - 1, "L"));
      now += (m - 1);
    } else if (m - 1 && now < k) {
      ans.push_back(pair<long long, string>(k - now, "L"));
      now += (k - now);
    }
    if (now == k) {
      print();
      return 0;
    }
    if (m - 1 && now + (m - 1) <= k) {
      ans.push_back(pair<long long, string>(m - 1, "R"));
      now += (m - 1);
    } else if (m - 1 && now < k) {
      ans.push_back(pair<long long, string>(k - now, "R"));
      now += (k - now);
    }
    if (now == k) {
      print();
      return 0;
    }
  }
  if (m - 1 && now + (m - 1) <= k) {
    ans.push_back(pair<long long, string>(m - 1, "L"));
    now += (m - 1);
  } else if (m - 1 && now < k) {
    ans.push_back(pair<long long, string>(k - now, "L"));
    now += (k - now);
  }
  print();
  return 0;
}
