import sys input = sys.stdin.read output = sys.stdout.write N = int(input().strip()) pigeon_counts = {} def query_pigeonhole(i, q): output(f'? {i}\n') sys.stdout.flush() count = int(input().strip()) pigeon_counts[i] = count return count for q in range(1, 11): if q <= N: query_pigeonhole(q, q) else: query_pigeonhole(1, q) reverse_lookup = {} found_duplicate = False result = "No\n" for pigeonhole, count in pigeon_counts.items(): if count in reverse_lookup: result = f"Yes\n{reverse_lookup[count]} {pigeonhole}\n" found_duplicate = True break reverse_lookup[count] = pigeonhole output(result)