#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  string color;
  cout << 0 << ' ' << 1 << endl;
  cin >> color;
  string tmp = color;
  int l = 0, r = 1e9;
  for (int i = 1; i < n; ++i) {
    int mid = (l + r) / 2;
    cout << mid << ' ' << 1 << endl;
    cin >> color;
    if (color == tmp) {
      l = mid;
    } else {
      r = mid;
    }
  }
  cout << l << ' ' << 0 << ' ' << r << ' ' << 2 << endl;
  return 0;
}
