#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  scanf("%d", &n);
  vector<int> v(n);
  for (int i = 0; i < n; i++) {
    scanf("%d", &v[i]);
  }
  double d1 = -1.0;
  double d2 = -1.0;
  int diff = v[0];
  int c = 2;
  for (int i = 1; i < v.size(); i++) {
    if (v[i] - v[i - 1] > diff) {
      if (d2 == -1.0) {
        d2 = diff + 1.0 / c;
        d1 = diff + 1.0 / (c - 1);
      }
    }
    if (d2 != -1.0) {
      if (d1 > double(v[i] + 1) / double(c)) d1 = double(v[i] + 1) / double(c);
      if (d2 < double(v[i]) / double(c)) d2 = double(v[i]) / double(c);
    }
    c++;
  }
  if (d2 == -1.0) {
    printf("not unique\n");
    return 0;
  }
  int a = floor(d2 * (double(v.size()) + 1.0));
  int b = floor(d1 * (double(v.size()) + 1.0));
  if (a != b && double(b) != d1 * (double(v.size()) + 1.0)) {
    printf("not unique\n");
  } else {
    printf("unique\n");
    printf("%d\n", a);
  }
  return 0;
}
