#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
const double eps = 1e-6;
int n, pos[1003];
int find(double key) {
  double cur = key;
  for (int i = 1; i <= n; ++i) {
    double cost = (pos[i] - pos[i - 1]) * 10.0;
    cur -= cost;
    cur += key;
  }
  return pos[n] + floor((cur + eps) / 10.0);
}
int judge(double key) {
  double cur = key;
  for (int i = 1; i <= n; ++i) {
    double cost = (pos[i] - pos[i - 1]) * 10.0;
    if (cur < cost) return -1;
    cur -= cost;
    if (cur > 10.0 - eps) return 1;
    cur += key;
  }
  return 0;
}
int findLow() {
  double low = 10, up = 1e7;
  while (fabs(low - up) > eps) {
    double mid = (low + up) / 2.0;
    int key = judge(mid);
    if (key == -1) {
      low = mid + eps;
    } else if (key == 1) {
      up = mid - eps;
    } else {
      up = mid - eps;
    }
  }
  return find(low + eps);
}
int findUp() {
  double low = 10, up = 1e7;
  while (fabs(low - up) > eps) {
    double mid = (low + up) / 2.0;
    int key = judge(mid);
    if (key == -1) {
      low = mid + eps;
    } else if (key == 1) {
      up = mid - eps;
    } else {
      low = mid + eps;
    }
  }
  return find(up - eps);
}
int main() {
  while (scanf("%d", &n) != EOF) {
    pos[0] = 0;
    for (int i = 1; i <= n; ++i) {
      scanf("%d", &pos[i]);
    }
    if (n == 1) {
      puts("not unique");
      continue;
    }
    int low = findLow();
    int up = findUp();
    if (low == up) {
      printf("unique\n%d\n", low);
    } else {
      puts("not unique");
    }
  }
  return 0;
}
