#include <bits/stdc++.h>
int ask(int i, int j) {
  std::cout << "? " << i + 1 << " " << j + 1 << std::endl;
  int r;
  std::cin >> r;
  return r;
}
int main() {
  std::unordered_map<int, std::pair<int, int>> mp;
  mp[4 * 8] = {4, 8};
  mp[4 * 15] = {4, 15};
  mp[4 * 16] = {4, 16};
  mp[4 * 23] = {4, 23};
  mp[4 * 42] = {4, 42};
  mp[8 * 15] = {8, 15};
  mp[8 * 16] = {8, 16};
  mp[8 * 23] = {8, 23};
  mp[8 * 42] = {8, 42};
  mp[15 * 16] = {15, 16};
  mp[15 * 23] = {15, 23};
  mp[15 * 42] = {15, 42};
  mp[16 * 23] = {16, 23};
  mp[16 * 42] = {16, 42};
  mp[23 * 42] = {23, 42};
  std::vector<int> ans(6, -1);
  int a = ask(0, 1);
  ans[0] = mp[a].first;
  ans[1] = mp[a].second;
  a = ask(1, 2);
  if (ans[1] == mp[a].first || ans[1] == mp[a].second) {
    ans[2] = mp[a].first ^ mp[a].second ^ ans[1];
  } else {
    std::swap(ans[0], ans[1]);
    ans[2] = mp[a].first ^ mp[a].second ^ ans[1];
  }
  a = ask(5, 4);
  ans[5] = mp[a].first;
  ans[4] = mp[a].second;
  a = ask(3, 4);
  if (ans[4] == mp[a].first || ans[4] == mp[a].second) {
    ans[3] = mp[a].first ^ mp[a].second ^ ans[4];
  } else {
    std::swap(ans[4], ans[5]);
    ans[3] = mp[a].first ^ mp[a].second ^ ans[4];
  }
  std::cout << "!";
  for (int x : ans) std::cout << " " << x;
  std::cout << std::endl;
}
