#include <bits/stdc++.h>
using namespace std;
const int MX = 1 << 10;
int n;
int bitcnt[MX * 10], mp[MX * 10];
int ass[MX * 10], acnt;
long long ret[MX];
int main() {
  cin >> n;
  for (int i = 1; i < (1 << 13); ++i) {
    bitcnt[i] = 1 + bitcnt[i - (i & -i)];
    if (bitcnt[i] == 6) ass[++acnt] = i;
  }
  for (int i = 1; i <= n; ++i) mp[ass[i]] = i;
  for (int i = 0; i < 13; ++i) {
    int cnt = 0;
    for (int j = 1; j <= n; ++j) {
      if (((ass[j] >> i) & 1) == 0) {
        ++cnt;
      }
    }
    if (!cnt) continue;
    cout << "? " << cnt << " ";
    for (int j = 1; j <= n; ++j) {
      if (((ass[j] >> i) & 1) == 0) {
        cout << j << " ";
      }
    }
    cout << endl;
    cin >> ret[i];
  }
  cout << "! ";
  for (int i = 1; i <= n; ++i) {
    long long Ans = 0;
    for (int j = 0; j < 13; ++j) {
      if ((ass[i] >> j) & 1) {
        Ans |= ret[j];
      }
    }
    cout << Ans << " ";
  }
  cout << endl;
}
