#include <bits/stdc++.h>
using namespace std;
const long long mod = 998244353;
const long long inf = 0x3f3f3f3f;
long long gcd(long long x, long long y) {
  if (y == 0)
    return x;
  else
    return gcd(y, x % y);
}
long long ksm(long long a, long long b) {
  long long r = 1;
  while (b) {
    if (b & 1) r = (r * a) % mod;
    a = a * a % mod;
    b >>= 1;
  }
  return r;
}
void exgcd(long long a, long long b, long long &x, long long &y, long long &d) {
  if (!b)
    d = a, x = 1, y = 0;
  else
    exgcd(b, a % b, y, x, d), y -= a / b * x;
}
long long inv(long long a, long long p) {
  long long x, y, d;
  exgcd(a, p, x, y, d);
  x = (x % p + p) % p;
  return x;
}
inline long long read() {
  char c = getchar();
  long long x = 0, f = 1;
  while (c < '0' || c > '9') {
    if (c == '-') f = -1;
    c = getchar();
  }
  while (c >= '0' && c <= '9') {
    x = x * 10 + c - '0';
    c = getchar();
  }
  return x * f;
}
const long long maxn = 1e5 + 100;
long long n, m, k, t;
char query(long long l, long long r) {
  cout << l << " " << r << endl;
  string s;
  cin >> s;
  if (l == r && s[0] == 'Y') exit(0);
  return s[0];
}
signed main() {
  srand(time(0));
  cin >> n >> k;
  long long l = 1, r = n;
  while (l <= r) {
    l = max(l - k, 1ll), r = min(r + k, n);
    long long mid = (l + r) >> 1;
    if (query(l, mid) == 'Y') {
      r = mid;
    } else {
      l = mid + 1;
    }
    if (r - l + 1 <= 3ll * k) {
      l = max(l - k, 1ll), r = min(r + k, n);
      long long id = l + rand() % (r - l + 1);
      if (query(id, id) == 'Y') {
        return 0;
      }
    }
  }
  return 0;
}
