#include <bits/stdc++.h>
using namespace std;
int query;
bool ask_exist(int n) {
  query--;
  cout << "> " << n << endl;
  bool ret;
  cin >> ret;
  cout.flush();
  return ret;
}
int ask_val(int pos) {
  cout << "? " << pos << endl;
  int ret;
  cin >> ret;
  cout.flush();
  return ret;
}
int gcd(int a, int b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
vector<int> v;
map<int, bool> m;
int main() {
  int n;
  srand(19260817);
  while (cin >> n) {
    int l = -1, r = 1e9;
    query = 60;
    v.clear();
    m.clear();
    while (l < r) {
      int mid = (l + r) >> 1;
      if (ask_exist(mid)) {
        l = mid + 1;
      } else
        r = mid;
    }
    int maxi = l;
    v.push_back(maxi);
    int know = 1;
    while (query--) {
      if (know >= n) break;
      int q = (long long)(rand() * rand()) % n;
      q++;
      if (m[q]) continue;
      m[q] = 1;
      int val = ask_val(q);
      if (val == maxi) continue;
      know++;
      v.push_back(val);
    }
    sort(v.begin(), v.end());
    vector<int> v2;
    v2.clear();
    for (int i = 0; i < v.size() - 1; i++) {
      for (int j = i + 1; j < v.size(); j++) {
        v2.push_back(v[j] - v[i]);
      }
    }
    sort(v2.begin(), v2.end());
    v2.erase(unique(v2.begin(), v2.end()), v2.end());
    int d = v2[0];
    for (int i = 1; i < v2.size(); i++) {
      d = gcd(d, v2[i]);
    }
    cout << "! " << maxi - d * (n - 1) << " " << d << endl;
    cout.flush();
  }
}
