#include <bits/stdc++.h>
const long long INF = 4e18L + 1;
const int IINF = 2e9 + 1;
const int limit = 1048576;
using namespace std;
template <class TH>
void _dbg(const char* sdbg, TH h) {
  cerr << sdbg << '=' << h << endl;
}
template <class TH, class... TA>
void _dbg(const char* sdbg, TH h, TA... a) {
  while (*sdbg != ',') cerr << *sdbg++;
  cerr << '=' << h << ',';
  _dbg(sdbg + 1, a...);
}
void pr(char c, int x) {
  cout << c << " " << x << endl;
  fflush(stdout);
}
vector<int> read(vector<vector<int>>& v, int x) {
  pr('?', x);
  int k;
  cin >> k;
  vector<int> ret(k);
  for (auto& y : ret) {
    cin >> y;
  }
  v[x] = ret;
  return ret;
}
pair<bool, vector<int>> init(vector<vector<int>>& v) {
  vector<int> path;
  vector<int> nei = read(v, 1);
  if ((int)((nei).size()) == 2) {
    pr('!', 1);
    return {1, path};
  }
  path.push_back(1);
  while (1) {
    if ((int)((v[path.back()]).size()) == 1) {
      return {0, path};
    }
    int x = path.back();
    int y;
    for (auto z : v[x]) {
      if ((int)((path).size()) == 1 or path[(int)((path).size()) - 2] != z) {
        y = z;
        break;
      }
    }
    vector<int> nei = read(v, y);
    if ((int)((nei).size()) == 2) {
      pr('!', y);
      return {1, path};
    }
    path.push_back(y);
  }
}
bool find_other(vector<vector<int>>& v, vector<int>& path) {
  while (1) {
    if ((int)((v[path.back()]).size()) == 1) {
      return 0;
    }
    int x = path.back();
    int y;
    for (auto z : v[x]) {
      if (path[(int)((path).size()) - 2] != z) {
        y = z;
        break;
      }
    }
    vector<int> nei = read(v, y);
    if ((int)((nei).size()) == 2) {
      pr('!', y);
      return 1;
    }
    path.push_back(y);
  }
}
bool cut(vector<vector<int>>& v, vector<int>& path) {
  int s = (int)((path).size()) / 2 + 1;
  int nope = path[s];
  path.resize(s);
  for (auto y : v[path.back()]) {
    if (y != path[s - 2] and y != nope) {
      vector<int> nei = read(v, y);
      if ((int)((nei).size()) == 2) {
        pr('!', y);
        return 1;
      }
      path.push_back(y);
      break;
    }
  }
  return 0;
}
void bfs(vector<vector<int>>& v, vector<int>& path) {
  vector<int> odw(129);
  odw[path[(int)((path).size()) - 1]] = 1;
  odw[path[(int)((path).size()) - 2]] = 1;
  queue<int> q;
  for (auto y : v[path.back()]) {
    if (!odw[y]) {
      q.push(y);
    }
  }
  int cnt = 0;
  while (1) {
    cnt++;
    int x = q.front();
    odw[x] = 1;
    q.pop();
    if (cnt == 6) {
      pr('!', x);
      return;
    }
    vector<int> nei = read(v, x);
    if ((int)((nei).size()) == 2) {
      pr('!', x);
      return;
    }
    for (auto y : nei) {
      if (!odw[y]) {
        q.push(y);
      }
    }
  }
}
int main() {
  int t;
  cin >> t;
  while (t--) {
    int h;
    cin >> h;
    vector<vector<int>> v(129);
    auto tmp = init(v);
    if (tmp.first == 1) {
      continue;
    }
    vector<int> path = tmp.second;
    reverse((path).begin(), (path).end());
    if ((int)((path).size()) == 1) {
      int x = v[path[0]][0];
      vector<int> nei = read(v, x);
      if ((int)((nei).size()) == 2) {
        pr('!', x);
        continue;
      }
      path.push_back(x);
    }
    if (find_other(v, path)) {
      continue;
    }
    if (cut(v, path)) {
      continue;
    }
    int czy = 0;
    while ((int)((path).size()) < 5) {
      if (find_other(v, path) or cut(v, path)) {
        czy = 1;
        break;
      }
    }
    if (czy) {
      continue;
    }
    bfs(v, path);
  }
}
