#include <bits/stdc++.h>
using namespace std;
long long n, k;
inline bool ask(long long l, long long r) {
  char s[5];
  printf("%lld %lld\n", l, r);
  fflush(stdout);
  scanf("%s", s + 1);
  if (s[1] == 'Y') return 1;
  return 0;
}
int main() {
  srand(time(NULL));
  scanf("%lld%lld", &n, &k);
  while (true) {
    long long l = 1, r = n, mid;
    while (r - l + 1 > 50) {
      mid = (l + r) / 2;
      if (ask(l, mid))
        r = mid - 1;
      else
        l = mid + 1;
      l = max(1LL, l - k);
      r = min(n, r + k);
    }
    long long pp = rand() % (r - l + 1) + l;
    if (ask(pp, pp)) return 0;
    l = max(1LL, l - k);
    r = min(n, r + k);
  }
}
