#include <bits/stdc++.h>
using namespace std;
long long tavan(long long a, long long b,
                long long mod = ((long long)1e9 + 7)) {
  long long res = 1;
  while (b) {
    res *= (b % 2) ? a : 1;
    res %= mod;
    a *= a;
    a %= mod;
    b /= 2;
  }
  return res;
}
long long n, sum, a[((long long)1100)];
long double l = 10, r = ((long long)1e9);
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> a[i];
    a[i] *= 10;
    l = max(l, (long double)(a[i] - a[i - 1] + sum) / i);
    r = min(r, (long double)(a[i] - a[i - 1] + 10 + sum) / i);
    sum = a[i];
  }
  l *= n + 1;
  r *= n + 1;
  if (floor(r) == r && ((long long)r) % 10 == 0) r--;
  long long l2 = l, r2 = r;
  if (l2 / 10 != r2 / 10) return cout << "not unique", 0;
  l2 /= 10;
  cout << "unique\n" << l2 << "\n";
  return 0;
}
