#include <bits/stdc++.h>
using i64 = long long;
int gcd(int a, int b) {
  if (b > a) std::swap(a, b);
  return a % b ? gcd(b, a % b) : b;
}
int main() {
  int n;
  scanf("%d", &n);
  i64 l = 0, r = 1000000001;
  int cnt = 0;
  while (r - l > 1) {
    i64 k = (l + r) / 2;
    printf("> %lld\n", k);
    fflush(stdout);
    i64 p;
    scanf("%lld", &p);
    if (p == -1)
      return 0;
    else if (p)
      l = k;
    else
      r = k;
    cnt++;
  }
  std::mt19937 engine(
      std::chrono::steady_clock::now().time_since_epoch().count());
  std::uniform_int_distribution<> dist(1, n);
  int d = -1;
  while (cnt++ <= 59) {
    auto k = dist(engine);
    printf("? %d\n", k);
    fflush(stdout);
    int p;
    scanf("%d", &p);
    if (p == -1) return 0;
    if (r == p) continue;
    if (d < 0)
      d = r - p;
    else
      d = gcd(d, r - p);
  }
  printf("! %lld %d\n", (i64)r - (i64)(n - 1) * (i64)d, d);
  return 0;
}
