#include <bits/stdc++.h>
using namespace std;
long long n, k;
bool judge(long long l, long long r) {
  cout << l << ' ' << r << endl;
  fflush(stdout);
  string s;
  cin >> s;
  return s[0] == 'Y';
}
int main() {
  srand(time(0));
  cin >> n >> k;
  long long l = 1, r = n;
  while (1) {
    l = max(l - k, 1ll);
    r = min(r + k, n);
    if (r - l <= 100) {
      long long w = rand() % (r - l + 1) + l;
      if (judge(w, w)) return 0;
    } else {
      long long mid = (l + r) / 2;
      if (judge(l, mid))
        r = mid;
      else
        l = mid + 1;
    }
  }
  return 0;
}
