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 M = 1000 + 10;
int a[M][M];
long long int downleft[M][M];
long long int down[M][M];
long long int downright[M][M];
long long int Right[M][M];
long long int rightup[M][M];
long long int rightdown[M][M];
long long int ans[M][M];
int main() {
  time_t t_start, t_end;
  t_start = clock();
  int n, m, k;
  cin >> n >> m >> k;
  for (int i = 1; i <= n; i++) {
    for (int j = 1; j <= m; j++) {
      cin >> a[i][j];
    }
  }
  for (int c = 1; c <= m; c++) {
    down[n][c] = a[n][c];
  }
  for (int r = n - 1; r >= 1; r--) {
    for (int c = 1; c <= m; c++) {
      down[r][c] = down[r + 1][c] + a[r][c];
    }
  }
  for (int c = 1; c <= m; c++) {
    for (int r = n; r >= 1; r--) {
      long long int n1 = 0;
      if (r + 1 <= n && c - 1 >= 1) {
        n1 = downleft[r + 1][c - 1];
      }
      downleft[r][c] = n1 + down[r][c];
    }
  }
  for (int c = m; c >= 1; c--) {
    for (int r = n; r >= 1; r--) {
      long long int n1 = 0;
      if (r + 1 <= n && c + 1 <= m) {
        n1 = downright[r + 1][c + 1];
      }
      downright[r][c] = n1 + down[r][c];
    }
  }
  for (int r = 1; r <= n; r++) {
    Right[r][m] = a[r][m];
  }
  for (int c = m - 1; c >= 1; c--) {
    for (int r = 1; r <= n; r++) {
      Right[r][c] = Right[r][c + 1] + a[r][c];
    }
  }
  for (int c = m; c >= 1; c--) {
    for (int r = 1; r <= n; r++) {
      long long int n1 = 0;
      if (r - 1 >= 1 && c + 1 <= m) {
        n1 = rightup[r - 1][c + 1];
      }
      rightup[r][c] = n1 + Right[r][c];
    }
  }
  for (int c = m; c >= 1; c--) {
    for (int r = n; r >= 1; r--) {
      long long int n1 = 0;
      if (r + 1 <= n && c + 1 <= m) {
        n1 = rightdown[r + 1][c + 1];
      }
      rightdown[r][c] = n1 + Right[r][c];
    }
  }
  long long int s1 = 0;
  for (int i = 1; i <= n; i++) {
    for (int j = 1; j <= m; j++) {
      s1 = s1 + a[i][j] * max(0, k - abs(i - k) - abs(j - k));
    }
  }
  ans[k][k] = s1;
  for (int r = k + 1; r <= n - k + 1; r++) {
    int c = k;
    int r1 = r - 1;
    int c1 = c;
    long long int a1 = rightup[r1][c - k + 1];
    int r2 = r1 - k;
    int c2 = c1 + 1;
    long long int a2 = 0;
    if (r2 >= 1 && c2 <= m) {
      a2 = rightup[r2][c2];
    }
    int r3 = r1 - k + 1;
    int c3 = c1 + 1;
    long long int a3 = 0;
    if (r3 >= 1 && c3 <= m) {
      a3 = rightdown[r3][c3];
    }
    int r4 = r1 + 1;
    int c4 = c1 + k + 1;
    long long int a4 = 0;
    if (r4 <= n && c4 <= m) {
      a4 = rightdown[r4][c4];
    }
    long long int t1 = a1 - a2 - (a3 - a4);
    r1 = r;
    c1 = c;
    a1 = rightdown[r][c - k + 1];
    r2 = r1 + k;
    c2 = c1 + 1;
    a2 = 0;
    if (r2 <= n && c2 <= m) {
      a2 = rightdown[r2][c2];
    }
    r3 = r2 - 1;
    c3 = c2;
    a3 = 0;
    if (r3 <= n && c3 <= m) {
      a3 = rightup[r3][c3];
    }
    r4 = r1 - 1;
    c4 = c1 + k + 1;
    a4 = 0;
    if (r4 >= 1 && c4 <= m) {
      a4 = rightup[r4][c4];
    }
    long long int t2 = a1 - a2 - (a3 - a4);
    ans[r][k] = ans[r - 1][k] - t1 + t2;
  }
  for (int r = k; r <= n - k + 1; r++) {
    for (int c = k + 1; c <= m - k + 1; c++) {
      int r1 = r;
      int c1 = c - 1;
      long long int a1 = downleft[r1 - k + 1][c1];
      int r2 = r1 + 1;
      int c2 = c1 - k;
      long long int a2 = 0;
      if (r2 <= n && c2 >= 1) {
        a2 = downleft[r2][c2];
      }
      int r3 = r2;
      int c3 = c2 + 1;
      long long int a3 = 0;
      if (r3 <= n && c3 <= m) {
        a3 = downright[r3][c3];
      }
      int r4 = r1 + k + 1;
      int c4 = c1 + 1;
      long long int a4 = 0;
      if (r4 <= n && c4 <= m) {
        a4 = downright[r4][c4];
      }
      long long int t1 = a1 - a2 - (a3 - a4);
      r1 = r;
      c1 = c;
      a1 = downright[r1 - k + 1][c1];
      r2 = r1 + 1;
      c2 = c1 + k;
      a2 = 0;
      if (r2 <= n && c2 <= m) {
        a2 = downright[r2][c2];
      }
      r3 = r1 + 1;
      c3 = c1 + k - 1;
      a3 = 0;
      if (r3 <= n && c3 <= m) {
        a3 = downleft[r3][c3];
      }
      r4 = r1 + k + 1;
      c4 = c1 - 1;
      a4 = 0;
      if (r4 <= n && c4 >= 1) {
        a4 = downleft[r4][c4];
      }
      long long int t2 = a1 - a2 - (a3 - a4);
      ans[r][c] = ans[r][c - 1] - t1 + t2;
    }
  }
  int ansr = k;
  int ansc = k;
  long long int ansv = ans[k][k];
  for (int r = k; r <= n - k + 1; r++) {
    for (int c = k; c <= m - k + 1; c++) {
      if (ans[r][c] > ansv) {
        ansv = ans[r][c];
        ansr = r;
        ansc = c;
      }
    }
  }
  cout << ansr << " " << ansc << endl;
  t_end = clock();
  return 0;
}