#include <bits/stdc++.h>
using namespace std;
const int M = 1000;
long long ma[2 * M + 10][2 * M + 10], n, m, k;
inline long long area(int a, int b, int c, int d) {
  return ma[c][d] + ma[a - 1][b - 1] - ma[c][b - 1] - ma[a - 1][d];
}
int main() {
  ios::sync_with_stdio(0);
  cin >> n >> m >> k;
  int xx = k, yy = k;
  long long ans = -1, tmp;
  for (int i = 1; i <= n; i++)
    for (int j = 1; j <= m; j++) cin >> ma[i + j][i - j + M];
  for (int i = 2; i <= n + m; i++)
    for (int j = 1 - m; j <= n - 1; j++) ma[i][j + M] += ma[i][j + M - 1];
  for (int i = 2; i <= n + m; i++)
    for (int j = 1 - m; j <= n - 1; j++) ma[i][j + M] += ma[i - 1][j + M];
  for (int i = k; i <= n - k + 1; i++)
    for (int j = k; j <= m - k + 1; j++) {
      tmp = 0;
      for (int l = 0; l < k; l++)
        tmp += area(i + j - l, i - j + M - l, i + j + l, i - j + M + l);
      if (tmp > ans) {
        ans = tmp;
        xx = i;
        yy = j;
      }
    }
  cout << xx << ' ' << yy << endl;
  return 0;
}
