#include <bits/stdc++.h>
using namespace std;
int a[55][55], ans[55];
int n;
int gao(int x) {
  for (int j = 0; j < n; j++) {
    int r = 0;
    for (int i = 0; i < n; i++)
      if (a[i][j] == x) r++;
    if (r == n - x) return j;
  }
}
int main() {
  while (~scanf("%d", &n)) {
    for (int i = 0; i < n; i++)
      for (int j = 0; j < n; j++) scanf("%d", &a[i][j]);
    memset(ans, 0, sizeof(ans));
    for (int i = 1; i < n; i++) ans[gao(i)] = i;
    for (int i = 0; i < n; i++)
      if (!ans[i]) {
        ans[i] = n;
        break;
      }
    for (int i = 0; i < n; i++) printf("%d%c", ans[i], " \n"[i == n - 1]);
  }
  return 0;
}
