#include <bits/stdc++.h>
using namespace std;
long long n, k;
mt19937_64 rng;
bool ask(long long l, long long r) {
  static char s[10];
  printf("%lld %lld\n", l, r);
  fflush(stdout);
  scanf("%s", s);
  return s[0] == 'Y';
}
int main() {
  long long lb, ub, m, k4;
  rng.seed(time(0));
  scanf("%lld%lld", &n, &k);
  k4 = k << 2;
  lb = 1;
  ub = n;
  for (;;) {
    while (ub - lb > k4) {
      m = (lb + ub) / 2;
      if (ask(lb, m))
        ub = m;
      else
        lb = m + 1;
      lb = max(1LL, lb - k);
      ub = min(n, ub + k);
    }
    m = lb + rng() % (ub - lb + 1);
    if (ask(m, m)) {
      return 0;
    }
    lb = max(1LL, lb - k);
    ub = min(n, ub + k);
  }
  return 0;
}
