#include <bits/stdc++.h>
using namespace std;
const long double PI = acos(-1.0);
const long long LINF = (long long)1e18 + 5;
const int INF = (int)1e9 + 5;
template <class T>
T sqr(T x) {
  return x * x;
}
template <class T>
T abs(T x) {
  return x < 0 ? -x : x;
}
template <class T>
long long round(T x) {
  return x < 0 ? x - 0.5 : x + 0.5;
}
template <class T>
bool chmin(T& x, const T& y) {
  if (y < x) {
    x = y;
    return true;
  }
  return false;
}
template <class T>
bool chmax(T& x, const T& y) {
  if (x < y) {
    x = y;
    return true;
  }
  return false;
}
template <class P, class Q>
ostream& operator<<(ostream& os, const pair<P, Q>& p) {
  return os << "(" << p.first << ", " << p.second << ")";
}
template <class T>
ostream& operator<<(ostream& os, const vector<T>& v) {
  bool was = false;
  os << "{";
  for (typename vector<T>::const_iterator it = v.begin(); it != v.end(); it++) {
    if (was) {
      os << ", ";
    } else {
      was = true;
    }
    os << *it;
  }
  os << "}";
  return os;
}
template <class T>
ostream& operator<<(ostream& os, const set<T>& v) {
  bool was = false;
  os << "{";
  for (typename set<T>::const_iterator it = v.begin(); it != v.end(); it++) {
    if (was) {
      os << ", ";
    } else {
      was = true;
    }
    os << *it;
  }
  os << "}";
  return os;
}
template <class T>
ostream& operator<<(ostream& os, const multiset<T>& v) {
  bool was = false;
  os << "{";
  for (typename multiset<T>::const_iterator it = v.begin(); it != v.end();
       it++) {
    if (was) {
      os << ", ";
    } else {
      was = true;
    }
    os << *it;
  }
  os << "}";
  return os;
}
template <class P, class Q>
ostream& operator<<(ostream& os, const map<P, Q>& v) {
  bool was = false;
  os << "{";
  for (typename map<P, Q>::const_iterator it = v.begin(); it != v.end(); it++) {
    if (was) {
      os << ", ";
    } else {
      was = true;
    }
    os << *it;
  }
  os << "}";
  return os;
}
template <class T>
T nextInt() {
  long long x = 0;
  bool p = false;
  char c;
  do {
    c = getchar();
  } while (c <= 32);
  if (c == '-') {
    p = true;
    c = getchar();
  }
  while (c >= '0' && c <= '9') {
    x = x * 10 + c - '0';
    c = getchar();
  }
  return (p ? -x : x);
}
int n;
vector<int> ask(vector<int> vec) {
  if (vec.empty()) {
    return vector<int>(n, (int)1e9);
  }
  cout << vec.size() << endl;
  for (int x : vec) {
    cout << x << " ";
  }
  cout << endl;
  vector<int> res;
  for (int i = 0; i < n; i++) {
    int x;
    cin >> x;
    res.push_back(x);
  }
  return res;
}
vector<int> dp[10][2];
int main(int argc, char* argv[]) {
  srand(time(0));
  cin >> n;
  for (int pos = 0; pos < 10; pos++) {
    for (int val = 0; val < 2; val++) {
      vector<int> vec;
      for (int x = 1; x <= n; x++) {
        if (((x >> pos) & 1) == val) vec.push_back(x);
      }
      dp[pos][val] = ask(vec);
    }
  }
  cout << -1 << endl;
  for (int i = 1; i <= n; i++) {
    int res = (int)1e9;
    for (int pos = 0; pos < 10; pos++) {
      int val = (i >> pos) & 1;
      val ^= 1;
      res = min(res, dp[pos][val][i - 1]);
    }
    cout << res << "\n";
  }
  fflush(stdout);
}
