#include <bits/stdc++.h>
using namespace std;
int main() {
  srand(time(NULL));
  long long n;
  int k;
  cin >> n >> k;
  long long L = 1;
  long long R = n;
  while (true) {
    if (R - L < 43) {
      int t = rand() % (int)(R - L + 1);
      cout << L + t << " " << L + t << endl;
      string s;
      cin >> s;
      if (s[0] == 'Y') {
        return 0;
      }
      L = max(1LL, L - k);
      R = min(n, R + k);
    } else {
      long long M = (L + R + 1) / 2;
      cout << L << " " << M << endl;
      string s;
      cin >> s;
      if (s[0] == 'Y') {
        L = max(1LL, L - k);
        R = min(n, M + k);
      } else {
        L = max(1LL, M + 1 - k);
        R = min(n, R + k);
      }
    }
  }
}
