#!/usr/bin/env python3
import sys

n = int(input())

def query(a,b):
    print('?',a,b, flush=True)
    return input()

def last_query(a,b):
    c = list(set([1,2,3]) - set([a,b]))[0]
    print('!', a if query(a,c) != 'equal' else b)
    sys.exit(0)

for k in range(1,n-1,2):
    if query(k,k+1) != 'equal':
        last_query(k,k+1)
last_query(n-1,n)
