#include <bits/stdc++.h>
using namespace std;
template <typename T1>
void print_list(const T1& a) {
  cerr << a << endl;
}
template <typename T1, typename T2>
void print_list(const T1& a, const T2& b) {
  cerr << a << " " << b << endl;
}
template <typename T1, typename T2, typename T3>
void print_list(const T1& a, const T2& b, const T3& c) {
  cerr << a << " " << b << " " << c << endl;
}
template <typename T1, typename T2, typename T3, typename T4>
void print_list(const T1& a, const T2& b, const T3& c, const T4& d) {
  cerr << a << " " << b << " " << c << " " << d << endl;
}
template <typename T1, typename T2, typename T3, typename T4, typename T5>
void print_list(const T1& a, const T2& b, const T3& c, const T4& d,
                const T5& e) {
  cerr << a << " " << b << " " << c << " " << d << " " << e << endl;
}
template <typename T1, typename T2, typename T3, typename T4, typename T5,
          typename T6>
void print_list(const T1& a, const T2& b, const T3& c, const T4& d, const T5& e,
                const T6& f) {
  cerr << a << " " << b << " " << c << " " << d << " " << e << " " << f << endl;
}
template <typename T1, typename T2, typename T3, typename T4, typename T5,
          typename T6, typename T7>
void print_list(const T1& a, const T2& b, const T3& c, const T4& d, const T5& e,
                const T6& f, const T7& g) {
  cerr << a << " " << b << " " << c << " " << d << " " << e << " " << f << " "
       << g << endl;
}
template <typename A, typename B>
ostream& operator<<(ostream& out, const pair<A, B>& pp) {
  out << "(" << pp.first << "," << pp.second << ")";
  return out;
}
template <typename A, typename B>
istream& operator<<(istream& in, pair<A, B>& pp) {
  cerr << "A pair wanted" << endl;
  in >> pp.first >> pp.second;
  return in;
}
template <typename T>
ostream& operator<<(ostream& out, const vector<T>& vect) {
  out << "length = " << vect.size() << endl;
  for (int i = 0; i < vect.size(); i++) out << vect[i] << " ";
  out << endl;
  return out;
}
template <typename T>
istream& operator>>(istream& in, vector<T>& vect) {
  vect.clear();
  int n;
  cerr << "A integer of length wanted" << endl;
  in >> n;
  vect.resize(n);
  cerr << n << " elements wanted" << endl;
  for (int i = 0; i < n; i++) in >> vect[i];
  return in;
}
template <typename T>
ostream& operator<<(ostream& out, const vector<vector<T> >& vect) {
  out << "row number=" << vect.size() << endl;
  for (int i = 0; i < vect.size(); i++) {
    out << "row #" << i << ":";
    for (int j = 0; j < vect[i].size(); j++) out << " " << vect[i][j];
    out << endl;
  }
  return out;
}
template <typename T>
istream& operator>>(istream& in, vector<vector<T> >& vect) {
  vect.clear();
  int n, m;
  cerr << "Two integers wnated" << endl;
  in >> n >> m;
  vect.resize(n);
  cerr << "A matrix " << n << " X " << m << " wanted" << endl;
  for (int i = 0; i < n; i++) {
    vect[i].resize(m);
    for (int j = 0; j < m; j++) in >> vect[i][j];
  }
  return in;
}
template <typename T>
inline void updateMax(T& a, const T& b) {
  a = max(a, b);
}
template <typename T>
inline void updateMin(T& a, const T& b) {
  a = min(a, b);
}
template <typename T>
inline vector<T> erase(vector<T> table, int ind) {
  assert(ind < table.size());
  table.erase(table.begin() + ind);
  return table;
}
template <typename T>
vector<T> unique(vector<T> table) {
  sort(table.begin(), table.end());
  return vector<T>(table.begin(), unique(table.begin(), table.end()));
}
template <class T>
vector<T> parse(const string& ss, const char* cut = " ") {
  vector<T> re;
  for (int j = 0; j < ss.size(); j++) {
    string s;
    while (j < ss.size() && NULL == strchr(cut, ss[j])) s += ss[j++];
    if (!s.empty()) {
      T tmp;
      istringstream is(s);
      is >> tmp;
      re.push_back(tmp);
    }
  }
  return re;
}
template <typename T>
T __gcd(T n, T m, T& a, T& b) {
  T a1 = 0, b1 = 1;
  a = 1, b = 0;
  while (m) {
    T c = n / m;
    T r = n - m * c;
    T t;
    t = a;
    a = a1;
    a1 = t - c * a1;
    t = b;
    b = b1;
    b1 = t - c * b1;
    n = m;
    m = r;
  }
  return n;
}
struct Node {
  int r, c, d;
  int v;
  Node(int x, int y, int z, int v1) : r(x), c(y), d(z), v(v1){};
  bool operator<(const Node& other) const { return v > other.v; };
};
priority_queue<Node> heap;
const int dir[][2] = {{-1, 0}, {0, 1},  {1, 0},  {0, -1},
                      {1, 1},  {1, -1}, {-1, 1}, {-1, -1}};
const char dname[] = "NWSE";
long long int __gcd(long long int a, long long int b) {
  while (b) {
    long long int r = a % b;
    a = b;
    b = r;
  }
  return a;
}
class fraction {
  long long int a, b;
  void simplify() {
    while (b == 0)
      ;
    assert(b);
    long long int g = __gcd(((a < 0) ? -(a) : (a)), ((b < 0) ? -(b) : (b)));
    a /= g;
    b /= g;
    if (b < 0) b = -b, a = -a;
  };

 public:
  fraction(long long int aa = 0, long long int bb = 1) : a(aa), b(bb) {
    assert(b);
    simplify();
  };
  void setValue(long long int aa, long long int bb) {
    a = aa, b = bb;
    assert(b);
    simplify();
  };
  void getValue(long long int& aa, long long int& bb) { aa = a, bb = b; };
  fraction operator+(const fraction& fb);
  fraction operator+=(const fraction& ff);
  fraction operator-(const fraction& ff);
  fraction operator-=(const fraction& ff);
  fraction operator*(const fraction& ff);
  fraction operator*=(const fraction& ff);
  fraction operator/(const fraction& ff);
  fraction operator/=(const fraction& ff);
  void print() { cout << a << "/" << b << endl; };
  friend bool operator==(const fraction& fa, const fraction& fb) {
    return fa.a == fb.a && fa.b == fb.b;
  };
  friend bool operator<(const fraction& fa, const fraction& fb) {
    fraction d = fraction(fa) - (fb);
    return d.a < 0;
  };
  friend bool operator>(const fraction& fa, const fraction& fb) {
    fraction d = fraction(fa) - fb;
    return d.a > 0;
  };
  friend ostream& operator<<(ostream& out, const fraction&);
};
ostream& operator<<(ostream& out, const fraction& ff) {
  out << ff.a << "/" << ff.b;
  return out;
}
fraction fraction::operator+(const fraction& fb) {
  long long int g =
      __gcd(((b < 0) ? -(b) : (b)), ((fb.b < 0) ? -(fb.b) : (fb.b)));
  fraction res;
  res.b = b / g * fb.b;
  res.a = a * (fb.b / g) + fb.a * (b / g);
  res.simplify();
  return res;
}
fraction fraction::operator+=(const fraction& fb) {
  fraction res = (*this) + fb;
  *this = res;
  return *this;
}
fraction fraction::operator-(const fraction& fb) {
  long long int g =
      __gcd(((b < 0) ? -(b) : (b)), ((fb.b < 0) ? -(fb.b) : (fb.b)));
  fraction res;
  res.b = b / g * fb.b;
  res.a = a * (fb.b / g) - fb.a * (b / g);
  res.simplify();
  return res;
}
fraction fraction::operator-=(const fraction& fb) {
  fraction res = (*this) - fb;
  *this = res;
  return *this;
}
fraction fraction::operator*(const fraction& fb) {
  long long int g1 =
      __gcd(((a < 0) ? -(a) : (a)), ((fb.b < 0) ? -(fb.b) : (fb.b)));
  long long int g2 =
      __gcd(((fb.a < 0) ? -(fb.a) : (fb.a)), ((b < 0) ? -(b) : (b)));
  fraction res(a / g1 * (fb.a / g2), b / g2 * (fb.b / g1));
  res.simplify();
  return res;
}
fraction fraction::operator*=(const fraction& fb) {
  fraction res = (*this) * fb;
  *this = res;
  return *this;
}
fraction fraction::operator/(const fraction& fb) {
  while (fb.a == 0)
    ;
  long long int g1 =
      __gcd(((a < 0) ? -(a) : (a)), ((fb.a < 0) ? -(fb.a) : (fb.a)));
  long long int g2 =
      __gcd(((fb.b < 0) ? -(fb.b) : (fb.b)), ((b < 0) ? -(b) : (b)));
  fraction res(a / g1 * (fb.b / g2), b / g2 * (fb.a / g1));
  res.simplify();
  return res;
}
fraction fraction::operator/=(const fraction& fb) {
  fraction res = (*this) / fb;
  *this = res;
  return *this;
}
int stop[1000];
int mult[1000];
int main() {
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) cin >> stop[i];
  fraction low(0, 1), high(1, 1);
  long long int top = 0;
  int base = stop[0];
  for (int i = 1; i < n; i++) {
    if (stop[i] - stop[i - 1] > base) {
      top++;
      if (low < fraction(top, i + 1)) low = fraction(top, i + 1);
    } else {
      if (high > fraction(top + 1, i + 1)) high = fraction(top + 1, i + 1);
    }
  };
  ;
  top++;
  long long int a, b;
  low.getValue(a, b);
  long long int z1 = a * (n + 1) / b;
  high.getValue(a, b);
  long long int z2 = (a * (n + 1) - 1) / b;
  assert(z2 >= z1);
  ;
  ;
  if (z1 < top && z2 >= top) {
    cout << "not unique" << endl;
  } else {
    cout << "unique" << endl;
    cout << (z1 >= top ? stop[n - 1] + base + 1 : stop[n - 1] + base) << endl;
  }
  return 0;
}
