#include <bits/stdc++.h>
using namespace std;
long long n;
int k;
char res[20];
int main() {
  srand(time(0));
  scanf("%lld%d", &n, &k);
  long long l = 1, r = n, mid;
  while (true) {
    if (r - l <= 5 * k) {
      long long pos = rand() % (r - l + 1) + l;
      printf("%lld %lld\n", pos, pos);
      fflush(stdout);
      scanf("%s", res);
      if (res[0] == 'Y' || res[0] == 'B')
        return 0;
      else {
        l = max(1ll, l - 2 * k);
        r = min(n, r + 2 * k);
      }
    } else {
      mid = (l + r) >> 1;
      printf("%lld %lld\n", l, mid);
      fflush(stdout);
      scanf("%s", res);
      if (res[0] == 'Y') {
        l = max(1ll, l - k);
        r = min(n, mid + k);
      } else if (res[0] == 'N') {
        l = max(1ll, mid - k + 1);
        r = min(n, r + k);
      } else
        return 0;
    }
  }
  return 0;
}
