#include <bits/stdc++.h>
using namespace std;
long long N;
vector<long long> pot, ans;
signed main() {
  cin >> N;
  for (long long i = 0; i < 1 << 13; ++i)
    if (__builtin_popcount(i) == 6) pot.push_back(i);
  for (long long p = 0; p < 13; ++p) {
    vector<long long> val;
    for (long long q = 1; q <= N; ++q)
      if (pot[q] >> p & 1) val.push_back(q);
    if (val.size()) {
      cout << "? " << val.size() << ' ';
      for (long long i = 0; i < val.size(); ++i) cout << val[i] << ' ';
      cout << endl;
      long long x;
      cin >> x;
      ans.push_back(x);
    } else
      ans.push_back(0);
  }
  cout << "! ";
  for (long long i = 1; i <= N; ++i) {
    long long sum = 0;
    for (long long j = 0; j < 13; ++j)
      if (!(pot[i] >> j & 1)) sum |= ans[j];
    cout << sum << ' ';
  }
  return 0;
}
