#include <bits/stdc++.h>
using namespace std;
const int N = 100000 + 10;
const int M = 1000000007;
const double eps = 1e-9;
const double PI = acos(-1);
const int oo = 1000000000;
long long n, k;
int ct = 0;
bool go(long long l, long long r) {
  cout << l << " " << r << endl;
  string ret;
  cin >> ret;
  if (ret[0] == 'Y') {
    if (l == r) exit(0);
    return 1;
  }
  return 0;
}
void calc(long long l, long long r) {
  if (r - l < 25) {
    int xx = rand() % (r - l + 1);
    go(l + xx, l + xx);
    return;
  }
  l = max(1ll, l - k);
  r = min(n, r + k);
  long long mid = (l + r) / 2;
  if (go(l, mid))
    calc(l, mid);
  else
    calc(mid + 1, r);
}
int main() {
  srand(time(NULL));
  cin >> n >> k;
  while (true) calc(1, n);
  return 0;
}
