#!/usr/bin/env python3

import random

W, H = map(int, input().split())
wp = list(range(1, W + 1))
random.shuffle(wp)


def is_building(i, y):
    print(f"? {wp[i]} {y}", flush=True)
    return input() == "building"


h = 0
hi = 0
for i in range(W):
    if not is_building(i, h + 1):
        continue
    hi = i
    h += 1
    # Binary search from 1 to H
    # This is less efficient that starting at h
    low = 1
    # NOTE: WA because this should be H+1
    high = H
    while low < high:
        m = (low + high) // 2
        if is_building(i, m):
            h = m
            low = m + 1
        else:
            high = m
    if h == H:
        break

print(f"! {wp[hi]} {h}", flush=True)
