import std.stdio, std.algorithm, std.conv, std.array, std.string, std.math, std.typecons, std.numeric;

void main()
{
    auto N = readln.chomp.to!int;
    writeln(0);
    auto f = readln.chomp;
    int l, r = N+1;
    for (;;) {
        auto m = (l+r)/2;
        writeln(m);
        auto x = readln.chomp;
        if (x == "Vacant") {
            return;
        } else if (x == f) {
            l = m;
        } else {
            r = m;
        }
    }
}