#include <bits/stdc++.h>
int a[51][51];
int p[51];
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++)
    for (int j = 1; j <= n; j++) scanf("%d", &a[i][j]);
  for (int k = 1; k <= n; k++) {
    for (int i = 1; i <= n; i++) {
      if (p[i] != 0) continue;
      int sum = 0;
      for (int j = 1; j <= n; j++) {
        if (p[j] != 0) continue;
        sum += a[i][j];
      }
      if (sum == k * (n - k)) {
        p[i] = k;
        break;
      }
    }
  }
  for (int i = 1; i <= n; i++) printf("%d ", p[i]);
  return 0;
}
