#include <bits/stdc++.h>
using namespace std;
template <class T>
using vv = vector<vector<T>>;
template <class T>
ostream &operator<<(ostream &os, const vector<T> &t) {
  os << "{";
  for (int(i) = 0; (i) < (t.size()); ++(i)) {
    os << t[i] << ",";
  }
  os << "}" << endl;
  return os;
}
template <class S, class T>
ostream &operator<<(ostream &os, const pair<S, T> &t) {
  return os << "(" << t.first << "," << t.second << ")";
}
template <class T>
inline bool MX(T &l, const T &r) {
  return l < r ? l = r, 1 : 0;
}
template <class T>
inline bool MN(T &l, const T &r) {
  return l > r ? l = r, 1 : 0;
}
const long long MOD = 1e9 + 7;
int n;
vector<int> ask(vector<int> &v) {
  cout << v.size() << endl;
  for (int(i) = 0; (i) < (v.size()); ++(i)) {
    if (i) cout << " ";
    cout << v[i] + 1;
  }
  cout << endl << flush;
  vector<int> re(n);
  for (int(i) = 0; (i) < (n); ++(i)) cin >> re[i], --re[i];
  return re;
}
int main() {
  ios_base::sync_with_stdio(false);
  cout << fixed << setprecision(0);
  cin >> n;
  vector<int> re(n, MOD);
  for (int(i) = 0; (i) < (10); ++(i)) {
    vector<int> v, w;
    for (int(j) = 0; (j) < (n); ++(j)) (j >> i & 1 ? v : w).push_back(j);
    if (v.size() == 0 || w.size() == 0) continue;
    vector<int> ansv = ask(v);
    vector<int> answ = ask(w);
    for (int(j) = 0; (j) < (n); ++(j))
      MN(re[j], (j >> i & 1 ? answ[j] : ansv[j]));
  }
  cout << -1 << endl << flush;
  for (int(i) = 0; (i) < (n); ++(i)) {
    if (i) cout << " ";
    cout << re[i] + 1;
  }
  cout << endl << flush;
  return 0;
}
