#include <bits/stdc++.h>
using namespace std;
int const inf = 1e9;
char in[10];
bool qu(int x, int y) {
  printf("%d %d\n", x, y);
  fflush(stdout);
  scanf("%s", in);
  return in[0] == 'b';
}
int main() {
  int n;
  scanf("%d", &n);
  bool x = qu(1, 0);
  int l = 1, r = inf;
  for (int i = 1; i < (int)(n); ++i) {
    int m = l + r >> 1;
    bool an = qu(1, m);
    if (an == x)
      l = m + 1;
    else
      r = m - 1;
  }
  printf("%d %d %d %d\n", 0, l, 2, r);
}
