#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, k;
  cin >> n >> m >> k;
  vector<pair<int, int> > a;
  for (int i = 0; i < n; i++) {
    if (i & 1) {
      for (int j = m - 1; j >= 0; j--) {
        a.push_back(make_pair(i + 1, j + 1));
      }
    } else {
      for (int j = 0; j < m; j++) {
        a.push_back(make_pair(i + 1, j + 1));
      }
    }
  }
  int x = 0;
  int part = int(a.size()) / k;
  for (int i = 0; i < k - 1; i++) {
    cout << part << ' ';
    for (int j = 0; j < part; j++) {
      cout << a[x].first << " " << a[x].second << " ";
      x++;
    }
    cout << endl;
  }
  cout << int(a.size() - x) << ' ';
  while (x < a.size()) {
    cout << a[x].first << ' ' << a[x].second << " ";
    x++;
  }
  cout << endl;
  return 0;
}
