#include <bits/stdc++.h>
using namespace std;
long long n;
int k;
char ans[10];
int main() {
  srand(time(0));
  scanf("%I64d%d", &n, &k);
  long long l = 1, r = n;
  while (1) {
    if (r - l > 4 * k) {
      long long m = l + r >> 1;
      printf("%I64d %I64d\n", l, m);
      fflush(stdout);
      scanf("%s", ans);
      if (ans[0] == 'Y')
        r = m;
      else
        l = m + 1;
      l = max(l - k, 1ll);
      r = min(r + k, n);
    } else {
      long long x = l + rand() % (r - l + 1);
      printf("%I64d %I64d\n", x, x);
      fflush(stdout);
      scanf("%s", ans);
      if (ans[0] == 'Y') return 0;
      l = max(l - k, 1ll);
      r = min(r + k, n);
    }
  }
}
