import heapq

class Node:
    def __init__(self, x):
        self.x = x

    def __lt__(self, o):
        print('?',self.x,o.x,flush=True)
        return int(input()) == o.x

n, k = map(int, input().split())

topk = heapq.nlargest(k, range(1, n+1), key=Node)

print('!',*topk)
