Problem: This is an interactive problem.

In good old times dwarves tried to develop extrasensory abilities:

  * Exactly n dwarves entered completely dark cave. 
  * Each dwarf received a hat — white or black. While in cave, none of the dwarves was able to see either his own hat or hats of other Dwarves. 
  * Dwarves went out of the cave to the meadow and sat at an arbitrary place one after the other. When a dwarf leaves the cave, he sees the colors of all hats of all dwarves that are seating on the meadow (i.e. left the cave before him). However, he is not able to see the color of his own hat and none of the dwarves can give him this information. 
  * The task for dwarves was to got diverged into two parts — one with dwarves with white hats and one with black hats. 



After many centuries, dwarves finally managed to select the right place on the meadow without error. Will you be able to repeat their success?

You are asked to successively name n different integer points on the plane. After naming each new point you will be given its color — black or white. Your task is to ensure that the named points can be split by a line in such a way that all points of one color lie on the same side from the line and points of different colors lie on different sides. Moreover, no points can belong to the line. Also, you need to report any such line at the end of the process.

In this problem, the interactor is adaptive — the colors of the points in the tests are not fixed beforehand and the jury program can select them arbitrarily, in particular, depending on your program output.

Interaction

The first line of the standard input stream contains an integer n (1 ≤ n ≤ 30) — the number of points your program should name.

Then n times your program must print two integer coordinates x and y (0 ≤ x ≤ 109, 0 ≤ y ≤ 109). All points you print must be distinct.

In response to each coordinate pair your program will receive the string "black", if the point is black, or "white", if the point is white.

When all n points are processed, you need to print four integers x1, y1, x2 and y2 (0 ≤ x1, y1 ≤ 109, 0 ≤ x2, y2 ≤ 109) — coordinates of points (x1, y1) and (x2, y2), which form a line, which separates n points into black and white. Points (x1, y1) and (x2, y2) should not coincide.

Hacks

To hack solution use the following format. The first line must contain word "hack", the second line should contain the number n and the last line should contain the sequence of 0 and 1 — colors of points, which will be reported to the solution. Unlike the jury tests, colors of points in hacks are always fixed in advance. Of course, the hacked solution wouldn't be able to get the information about the colors in advance.

For example, the hack corresponding to sample test will look like this: 
    
    
      
    hack  
    5  
    0 0 1 1 0  
    

Example

Input

5
<span class="tex-span"></span>
black
<span class="tex-span"></span>
black
<span class="tex-span"></span>
white
<span class="tex-span"></span>
white
<span class="tex-span"></span>
black


Output

<span class="tex-span"></span>
0 0
<span class="tex-span"></span>
3 1
<span class="tex-span"></span>
2 3
<span class="tex-span"></span>
4 4
<span class="tex-span"></span>
0 2
<span class="tex-span"></span>
1 3 4 1

Note

In the sample input and output values are aligned only for simplicity of interpreting them chronologically. In real interaction no "extra" line breaks should appear.

The following picture illustrates the first test.

<image>

Solution (in JAVA):

Solution:
import javafx.util.*;
import java.util.*;
import java.io.*;
import java.math.*;

public class Test8{

    Random rnd = new Random();
    PrintWriter pw = new PrintWriter(System.out);
    int a;

    void run() {
        Scanner s = new Scanner(System.in);
        int a = s.nextInt(), l = 0, r = 500000000, y = 100, mid;
        System.out.println(l+" "+y);
        System.out.flush();
        String t = s.next();
        if(a>1){
            System.out.println(r+" "+y);
            System.out.flush();
            if(s.next().equals(t)){
               l = r;
               r = 1000000000;
            }
        }
        for(int q=2; q<a; q++){
            mid = (r+l)/2;
            System.out.println(mid+" "+y);
            System.out.flush();
            if(s.next().equals(t)) l = mid;
            else r = mid;
        }
        System.out.println(l+" "+(y-1)+" "+r+" "+(y+1));
        System.out.flush();
        pw.flush();
    }

    public static void main(String[] args) {
        new Test8().run();
    }

    InputStream is = System.in;
    private byte[] inbuf = new byte[1024];
    public int lenbuf = 0, ptrbuf = 0;

    private int readByte() {
        if (lenbuf == -1) throw new InputMismatchException();
        if (ptrbuf >= lenbuf) {
            ptrbuf = 0;
            try {
                lenbuf = is.read(inbuf);
            } catch (IOException e) {
                throw new InputMismatchException();
            }
            if (lenbuf <= 0) return -1;
        }
        return inbuf[ptrbuf++];
    }

    private boolean isSpaceChar(int c) {
        return !(c >= 33 && c <= 126);
    }

    private int skip() {
        int b;
        while ((b = readByte()) != -1 && isSpaceChar(b)) ;
        return b;
    }

    private double nd() {
        return Double.parseDouble(ns());
    }

    private char nc() {
        return (char) skip();
    }

    private String ns() {
        int b = skip();
        StringBuilder sb = new StringBuilder();
        while (!(isSpaceChar(b))) {
            sb.appendCodePoint(b);
            b = readByte();
        }
        return sb.toString();
    }

    private char[] ns(int n) {
        char[] buf = new char[n];
        int b = skip(), p = 0;
        while (p < n && !(isSpaceChar(b))) {
            buf[p++] = (char) b;
            b = readByte();
        }
        return n == p ? buf : Arrays.copyOf(buf, p);
    }

    private char[][] nm(int n, int m) {
        char[][] map = new char[n][];
        for (int i = 0; i < n; i++) map[i] = ns(m);
        return map;
    }

    private int[] na(int n) {
        int[] a = new int[n];
        for (int i = 0; i < n; i++) a[i] = ni();
        return a;
    }

    private int ni() {
        int num = 0, b;
        boolean minus = false;
        while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-')) ;
        if (b == '-') {
            minus = true;
            b = readByte();
        }
        while (true) {
            if (b >= '0' && b <= '9') {
                num = num * 10 + (b - '0');
            } else {
                return minus ? -num : num;
            }
            b = readByte();
        }
    }

    private long nl() {
        long num = 0;
        int b;
        boolean minus = false;
        while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-')) ;
        if (b == '-') {
            minus = true;
            b = readByte();
        }
        while (true) {
            if (b >= '0' && b <= '9') {
                num = num * 10 + (b - '0');
            } else {
                return minus ? -num : num;
            }
            b = readByte();
        }
    }
}

class Drobis {

    BigInteger celchact;
    BigInteger chislitel=BigInteger.ZERO;
    BigInteger snamenatel=BigInteger.ONE;

    Drobis(long ce, long del, long delit){
        BigInteger delimoe = BigInteger.valueOf(del);
        BigInteger delitel = BigInteger.valueOf(delit);
        celchact = delimoe.divide(delitel);
        delimoe=delimoe.mod(delitel);
        if(delimoe.compareTo(BigInteger.ZERO)!=0){
            BigInteger d = gcd(delimoe, delitel);
            delimoe=delimoe.divide(d);
            delitel=delitel.divide(d);
            chislitel=delimoe;
            snamenatel=delitel;
        }
        celchact=celchact.add(BigInteger.valueOf(ce));
    }

    Drobis(BigInteger cel,  BigInteger delimoe, BigInteger delitel){
        celchact = delimoe.divide(delitel);
        delimoe=delimoe.mod(delitel);
        if(delimoe.compareTo(BigInteger.ZERO)!=0){
            BigInteger d = gcd(delimoe, delitel);
            delimoe=delimoe.divide(d);
            delitel=delitel.divide(d);
            chislitel=delimoe;
            snamenatel=delitel;
        }
        celchact=celchact.add(cel);
    }

    static BigInteger gcd(BigInteger a, BigInteger b){
        for(; (a.multiply(b)).compareTo(BigInteger.ZERO)>0;)
            if(a.compareTo(b)>0) a=a.mod(b);
            else b=b.mod(a);
        return a.add(b);
    }

    static int comparewithint(Drobis a, long b){
        if(a.celchact.compareTo(BigInteger.valueOf(b))==0){
            if(a.chislitel.compareTo(BigInteger.ZERO)>0) return 1;
            else return 0;
        }
        else if(a.celchact.compareTo(BigInteger.valueOf(b))>0) return 1;
        else return -1;
    }

    static int compare(Drobis a, Drobis b){
        if(a.celchact.compareTo(b.celchact)==0){
            if(a.chislitel.compareTo(b.chislitel)==0 & a.snamenatel.compareTo(b.snamenatel)==0) return 0;
            else if((a.chislitel.multiply(b.snamenatel)).compareTo(a.snamenatel.multiply(b.chislitel))>0) return 1;
            else return -1;
        }
        else if(a.celchact.compareTo(b.celchact)>0) return 1;
        else return -1;
    }

    static int comparedrobnchast(Drobis a, Drobis b){
        if(a.chislitel.compareTo(b.chislitel)==0 & a.snamenatel.compareTo(b.snamenatel)==0) return 0;
        else if((a.chislitel.multiply(b.snamenatel)).compareTo(a.snamenatel.multiply(b.chislitel))>0) return 1;
        else return -1;
    }

    void print(){
        System.out.print(celchact+" ");
        if(chislitel.compareTo(BigInteger.ZERO)>0) System.out.println(chislitel+"/"+snamenatel);
    }

    static Drobis add(Drobis a, Drobis b){
        BigInteger celoe = a.celchact.add(b.celchact);
        BigInteger chis = a.chislitel.multiply(b.snamenatel).add(b.chislitel.multiply(a.snamenatel));
        BigInteger snam = a.snamenatel.multiply(b.snamenatel), gcd = gcd(chis, snam);
        chis = chis.divide(gcd);
        snam = snam.divide(gcd);
        if(chis.compareTo(snam)>=0){
            celoe = celoe.add(BigInteger.ONE);
            chis = chis.subtract(snam);
            if(chis.compareTo(BigInteger.ZERO)==0) snam = BigInteger.ONE;
        }
        return new Drobis(celoe,chis,snam);
    }

    static Drobis subsr(Drobis a, Drobis b){
        BigInteger celoe = a.celchact.subtract(b.celchact);
        if(comparedrobnchast(a,b)<0) celoe=celoe.subtract(BigInteger.ONE);
        BigInteger cnam = a.snamenatel.multiply(b.snamenatel).divide(gcd(a.snamenatel, b.snamenatel)), umna = cnam.divide(a.snamenatel), umnb=cnam.divide(b.snamenatel);
        BigInteger newchisl = (a.chislitel.multiply(umna)).subtract(b.chislitel.multiply(umnb));
        if(newchisl.compareTo(BigInteger.ZERO)<0) newchisl = cnam.add(newchisl);
        return new Drobis(celoe,newchisl,cnam.compareTo(BigInteger.ONE)>0 ? cnam : BigInteger.ONE);
    }

    static Drobis multiply(Drobis a, Drobis b){
        BigInteger chis = a.celchact.multiply(a.snamenatel).add(a.chislitel).multiply(b.celchact.multiply(b.snamenatel).add(b.chislitel));
        BigInteger snam = a.snamenatel.multiply(b.snamenatel);
        BigInteger gcd = gcd(chis,snam);
        chis=chis.divide(gcd);
        snam=snam.divide(gcd);
        BigInteger cel = chis.divide(snam);
        chis = chis.mod(snam);
        if(chis.compareTo(BigInteger.ZERO)==0) snam=BigInteger.ONE;
        return new Drobis(cel,chis,snam);
    }

    static Drobis divide(Drobis a, Drobis b){
        BigInteger chis = b.snamenatel.multiply(a.celchact.multiply(a.snamenatel).add(a.chislitel));
        BigInteger snam = a.snamenatel.multiply(b.celchact.multiply(b.snamenatel).add(b.chislitel));
        if(snam.compareTo(BigInteger.ZERO)==0){
            System.out.println("Naxyu ti delish na 0? Ne nado tak.");
            throw new ArithmeticException();
        }
        else{
            BigInteger gcd = gcd(chis,snam);
            chis=chis.divide(gcd);
            snam=snam.divide(gcd);
            BigInteger cel = chis.divide(snam);
            chis = chis.mod(snam);
            if(chis.compareTo(BigInteger.ZERO)==0) snam=BigInteger.ONE;
            return new Drobis(cel,chis,snam);
        }
    }
}