#include <bits/stdc++.h>
template <typename T>
inline void rd(T& x) {
  int si = 1;
  char c = getchar();
  x = 0;
  while (!isdigit(c)) si = c == '-' ? -1 : si, c = getchar();
  while (isdigit(c)) x = x * 10 + c - 48, c = getchar();
  x *= si;
}
template <typename T, typename... Args>
inline void rd(T& x, Args&... args) {
  rd(x);
  rd(args...);
}
const int kN = 4e5 + 5, kInf = 0x3f3f3f3f;
const long long kMod = 998244353, kInfLL = 0x3f3f3f3f3f3f3f3fLL;
int n, len, cnt = 0, tot, a[kN], b[kN], d[kN], buc[kN], fa[kN];
int Find(int x) { return fa[x] == x ? x : fa[x] = Find(fa[x]); }
void Merge(int x, int y) {
  int f_x = Find(x), f_y = Find(y);
  if (f_x == f_y) return;
  fa[Find(x)] = Find(y);
  --tot;
}
int main() {
  int T = 1;
  while (T--) {
    printf("%d\n", -1);
  }
  return 0;
}
