#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 17;
int in[] = {0, 4, 8, 15, 16, 23, 42};
int out[7];
int query(int x, int y) {
  cout << "? " << x << " " << y << endl;
  fflush(stdout);
  cin >> x;
  if (!x) exit(0);
  return x;
}
int main() {
  int x = 2;
  for (int q = 0; q < 2; q++) {
    int AB = query(x - 1, x), BC = query(x, x + 1);
    bool done = false;
    for (int i = 1; !done && i <= 6; i++)
      for (int j = 1; !done && j <= 6; j++)
        for (int k = 1; !done && k <= 6; k++)
          if (i != j && j != k && i != k && in[i] * in[j] == AB &&
              in[j] * in[k] == BC) {
            done = true;
            out[x - 1] = in[i];
            out[x] = in[j];
            out[x + 1] = in[k];
            in[i] = in[j] = in[k] = 0;
          }
    x += 3;
  }
  cout << "! ";
  for (int i = 1; i <= 6; i++) cout << out[i] << " ";
  cout << endl;
  fflush(stdout);
  return 0;
}
