Problem: You've got a table of size n × m. On the intersection of the i-th row (1 ≤ i ≤ n) and the j-th column (1 ≤ j ≤ m) there is a non-negative integer ai, j. Besides, you've got a non-negative integer k.

Your task is to find such pair of integers (a, b) that meets these conditions: 

  * k ≤ a ≤ n - k + 1; 
  * k ≤ b ≤ m - k + 1; 
  * let's denote the maximum of the function <image> among all integers x and y, that satisfy the inequalities k ≤ x ≤ n - k + 1 and k ≤ y ≤ m - k + 1, as mval; for the required pair of numbers the following equation must hold f(a, b) = mval. 

Input

The first line contains three space-separated integers n, m and k (1 ≤ n, m ≤ 1000, <image>). Next n lines each contains m integers: the j-th number on the i-th line equals ai, j (0 ≤ ai, j ≤ 106).

The numbers in the lines are separated by spaces.

Output

Print the required pair of integers a and b. Separate the numbers by a space.

If there are multiple correct answers, you are allowed to print any of them.

Examples

Input

4 4 2
1 2 3 4
1 1 1 1
2 2 2 2
4 3 2 1


Output

3 2


Input

5 7 3
8 2 3 4 2 3 3
3 4 6 2 3 4 6
8 7 6 8 4 5 7
1 2 3 2 1 3 2
4 5 3 2 1 2 1


Output

3 3

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int MAXN = 1002;
vector<vector<long long> > digl(MAXN, vector<long long>(MAXN));
vector<vector<long long> > digr(MAXN, vector<long long>(MAXN));
vector<vector<long long> > H(MAXN, vector<long long>(MAXN));
vector<vector<long long> > V(MAXN, vector<long long>(MAXN));
int mat[MAXN][MAXN];
long long triangles1[MAXN][MAXN];
long long triangles2[MAXN][MAXN];
long long Rhombus[MAXN][MAXN];
long long result[MAXN][MAXN];
int h, w, k;
long long get_digl_sm(int i, int j, int K) {
  long long sm = 0;
  while (K) K--, sm += mat[i][j], i++, j++;
  return sm;
}
long long get_H_sm(int i, int j, int K) {
  long long sm = 0;
  while (K) K--, sm += mat[i][j], i++;
  return sm;
}
long long get_V_sm(int i, int j, int K) {
  long long sm = 0;
  while (K) K--, sm += mat[i][j], j++;
  return sm;
}
void init(vector<vector<long long> >& dig) {
  for (int i = 0; i < h - k + 1; i++) dig[i][0] = get_digl_sm(i, 0, k);
  for (int i = 0; i < w - k + 1; i++) dig[0][i] = get_digl_sm(0, i, k);
  for (int i = 1; i < h - k + 1; i++)
    for (int j = 1; j < w - k + 1; j++)
      dig[i][j] =
          dig[i - 1][j - 1] - mat[i - 1][j - 1] + mat[i + k - 1][j + k - 1];
}
void initl() { init(digl); }
void initr() {
  for (int i = 0; i < h; i++) reverse(mat[i], mat[i] + w);
  init(digr);
  for (int i = 0; i < h; i++)
    reverse(mat[i], mat[i] + w), reverse(digr[i].begin(), digr[i].begin() + w);
}
void initH() {
  int K = 2 * k - 1;
  for (int j = 0; j < w; j++) H[0][j] = get_H_sm(0, j, K);
  for (int i = 1; i < h - K + 1; i++)
    for (int j = 0; j < w; j++)
      H[i][j] = H[i - 1][j] - mat[i - 1][j] + mat[i + K - 1][j];
}
void initV() {
  int K = 2 * k - 1;
  for (int i = 0; i < h; i++) V[i][0] = get_V_sm(i, 0, K);
  for (int i = 0; i < h; i++)
    for (int j = 1; j < w - K + 1; j++)
      V[i][j] = V[i][j - 1] - mat[i][j - 1] + mat[i][j + K - 1];
}
void step1() {
  initl();
  initr();
  initH();
  initV();
}
long long get_Rhombus_sum(int a, int b) {
  long long sm = 0;
  for (int i = 0; i < h; i++)
    for (int j = 0; j < w; j++)
      sm += mat[i][j] * (long long)max(0, min(1, k - abs(i - a) - abs(j - b)));
  return sm;
}
void step2() {
  long long val = get_Rhombus_sum(k - 1, k - 1);
  Rhombus[k - 1][k - 1] = val;
  for (int i = k - 1; i < h - k + 1; i++) {
    for (int j = k; j < w - k + 1; j++)
      Rhombus[i][j] = Rhombus[i][j - 1],
      Rhombus[i][j] -= digr[i - k + 1][j - 1] + digl[i][j - 1 - k + 1],
      Rhombus[i][j] += digl[i - k + 1][j] + digr[i][j + k - 1],
      Rhombus[i][j] += mat[i][j - 1 - k + 1],
      Rhombus[i][j] -= mat[i][j + k - 1];
    if (i + 1 < (h - k + 1))
      Rhombus[i + 1][k - 1] = Rhombus[i][k - 1],
                         Rhombus[i + 1][k - 1] -= digl[i - k + 1][k - 1] +
                                                  digr[i - k + 1][k - 1] -
                                                  mat[i - k + 1][k - 1],
                         Rhombus[i + 1][k - 1] += digl[i + 1][k - 1 - k + 1] +
                                                  digr[i + 1][k - 1 + k - 1] -
                                                  mat[i + 1 + k - 1][k - 1];
  }
}
long long get_Tri_sum(int a, int b) {
  long long sm = 0;
  for (int i = 0; i < h; i++)
    for (int j = 0; j < k; j++)
      sm += mat[i][j] * (long long)max(0, min(1, k - abs(i - a) - abs(j - b)));
  return sm;
}
long long get_Tri2_sum(int a, int b) {
  long long sm = 0;
  for (int i = 0; i < k; i++)
    for (int j = 0; j < w; j++)
      sm += mat[i][j] * (long long)max(0, min(1, k - abs(i - a) - abs(j - b)));
  return sm;
}
void step3() {
  long long val = get_Tri_sum(k - 1, k - 1);
  triangles1[k - 1][k - 1] = val;
  for (int i = k - 1; i < h - k + 1; i++) {
    for (int j = k; j < w - k + 1; j++)
      triangles1[i][j] = triangles1[i][j - 1],
      triangles1[i][j] -= digr[i - k + 1][j - 1] + digl[i][j - 1 - k + 1] -
                          mat[i][j - 1 - k + 1],
      triangles1[i][j] += H[i - k + 1][j];
    if (i + 1 < (h - k + 1))
      triangles1[i + 1][k - 1] = triangles1[i][k - 1],
                            triangles1[i + 1][k - 1] -= digr[i - k + 1][k - 1],
                            triangles1[i + 1][k - 1] +=
                            digl[i + 1][k - 1 - k + 1];
  }
  triangles2[k - 1][k - 1] = get_Tri2_sum(k - 1, k - 1);
  for (int i = k - 1; i < h - k + 1; i++) {
    for (int j = k; j < w - k + 1; j++)
      triangles2[i][j] = triangles2[i][j - 1],
      triangles2[i][j] -= digr[i - k + 1][j - 1],
      triangles2[i][j] += digl[i - k + 1][j];
    if (i + 1 < (h - k + 1))
      triangles2[i + 1][k - 1] = triangles2[i][k - 1],
                            triangles2[i + 1][k - 1] -= digr[i - k + 1][k - 1],
                            triangles2[i + 1][k - 1] -= digl[i - k + 1][k - 1],
                            triangles2[i + 1][k - 1] += mat[i - k + 1][k - 1],
                            triangles2[i + 1][k - 1] += V[i + 1][0];
  }
}
long long get_Rhombus_sum2(int a, int b) {
  long long sm = 0;
  for (int i = 0; i < h; i++)
    for (int j = 0; j < w; j++)
      sm += mat[i][j] * (long long)max(0, k - abs(i - a) - abs(j - b));
  return sm;
}
void step4() {
  long long val = get_Rhombus_sum2(k - 1, k - 1);
  result[k - 1][k - 1] = val;
  for (int i = k - 1; i < h - k + 1; i++) {
    for (int j = k; j < w - k + 1; j++)
      result[i][j] = result[i][j - 1] - triangles1[i][j - 1],
      result[i][j] += Rhombus[i][j] - triangles1[i][j] + H[i - k + 1][j];
    if (i + 1 < (h - k + 1))
      result[i + 1][k - 1] = result[i][k - 1],
                        result[i + 1][k - 1] -= triangles2[i][k - 1],
                        result[i + 1][k - 1] +=
                        Rhombus[i + 1][k - 1] - triangles2[i + 1][k - 1],
                        result[i + 1][k - 1] += V[i + 1][0];
  }
}
int main() {
  scanf("%d%d%d", &h, &w, &k);
  for (int i = 0; i < h; i++)
    for (int j = 0; j < w; j++) scanf("%d", &mat[i][j]);
  step1();
  step2();
  step3();
  step4();
  int a, b;
  long long mx = -1;
  for (int i = k - 1; i < h - k + 1; i++)
    for (int j = k - 1; j < w - k + 1; j++)
      if (result[i][j] > mx) mx = result[i][j], a = i, b = j;
  printf("%d %d", a + 1, b + 1);
}