#include <bits/stdc++.h>
using namespace std;
int n, m, k, i, j, a[1500001][2], l;
int main() {
  cin >> n >> m >> k;
  for (i = 1; i <= n; i++) {
    if (i % 2 != 0) {
      for (j = 1; j <= m; j++) {
        l++;
        a[l][0] = i;
        a[l][1] = j;
      }
    } else {
      for (j = m; j >= 1; j--) {
        l++;
        a[l][0] = i;
        a[l][1] = j;
      }
    }
  }
  for (i = 1; i < k * 2; i++)
    if (i % 2 == 0)
      cout << "2"
           << " " << a[i - 1][0] << " " << a[i - 1][1] << " " << a[i][0] << " "
           << a[i][1] << endl;
  cout << l - ((k * 2) - 2) << " ";
  for (i = (k * 2) - 1; i < l; i++) cout << a[i][0] << " " << a[i][1] << " ";
  cout << a[l][0] << " " << a[l][1] << endl;
  return 0;
}
