#include <bits/stdc++.h>
using namespace std;
inline long long read() {
  long long x = 0, f = 1;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    x = (x << 3) + (x << 1) + ch - '0';
    ch = getchar();
  }
  return x * f;
}
long long n, k, rd;
long long a, b, l, r;
char ch[5];
int main() {
  srand(919260817);
  n = read();
  k = read();
  a = 1, b = n;
  while (1) {
    if (a + 45 > b) {
      rd = rand() % (b - a + 1) + a;
      printf("%lld %lld\n", rd, rd);
      fflush(stdout);
      scanf("%s", ch + 1);
      if (ch[1] == 'Y')
        break;
      else {
        a = max(1LL, a - k);
        b = min(n, b + k);
      }
    } else {
      l = a;
      r = (a + b) >> 1;
      printf("%lld %lld\n", l, r);
      fflush(stdout);
      scanf("%s", ch + 1);
      if (ch[1] == 'Y') {
        a = max(1LL, l - k);
        b = min(n, r + k);
      }
      if (ch[1] == 'N') {
        a = max(1LL, r + 1 - k);
        b = min(n, b + k);
      }
    }
  }
  return 0;
}
