#include <bits/stdc++.h>
using namespace std;
const long long INF = 1e18;
const long long mod = 1e9 + 7;
const long long N = 1e5 + 10;
inline long long add(long long x, long long y) {
  x += y;
  if (x >= mod) x -= mod;
  return x;
}
inline long long mul(long long x, long long y) {
  x = (1LL * x * y) % mod;
  return x;
}
int main() {
  ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
  long long n;
  cin >> n;
  n--;
  cout << "0 0" << endl;
  fflush(stdout);
  if (n == 0) {
    cout << "1 0 1 1";
    fflush(stdout);
    return 0;
  }
  string prev;
  cin >> prev;
  long long l = 0;
  long long r = 1e9;
  long long i = 1;
  while (i <= n) {
    long long m = (l + r) / 2;
    cout << m << " "
         << "0" << endl;
    fflush(stdout);
    string s;
    cin >> s;
    if (s == prev) {
      l = m;
    } else {
      r = m;
    }
    i++;
  }
  if (r - l < 2) {
    cout << r << " 1 " << (r + 1) << " " << (2 * (r + 1) - 2 * l - 1);
    fflush(stdout);
    return 0;
  }
  long long m = (l + r) / 2;
  cout << m << " 0 " << m << " 1";
  fflush(stdout);
  return 0;
}
