#include<stdio.h>
#include<string>
#include<map>
#include<vector>
#include<queue>
#include<iostream>
#include<set>
#include<math.h>
#include<algorithm>

#pragma warning (disable:4996)

#define ll long long int
#define mp make_pair

using namespace std;

int n, a[3005];

bool ch(int q,int m) {
	int i, x,st[3005],sum;
	for (i = 0; i < m+3; i++) {
		st[i] = 0;
	}
	for (i = q; i < m; i++) {
		st[a[i]] = 1;
	}
	for (i = 0; i < m + 3; i++) {
		sum += st[i];
	}
	printf("? %d %d\n", q + 1, m + 1);
	fflush(stdout);
	scanf("%d", &x);
	if (x == sum) {
		return true;
	}
	return false;
}

void solve() {
	int i, j, l, r, m, t = 1, x,st[3005],sum;
	a[0] = 1;
	for (i = 1; i < n; i++) {
		l = 0;
		r = i;
		printf("? 1 %d\n", i + 1);
		fflush(stdout);
		scanf("%d", &x);
		for (j = 0; j < i; j++) {
			st[a[j]] = 0;
		}
		for (j = 0; j < i; j++) {
			st[a[j]] = 1;
		}
		sum = 0;
		for (j = 0; j < i; j++) {
			sum += st[j];
		}
		if (x == sum + 1) {
			t++;
			a[i] = t;
		}
		else {
			while (r - l > 1) {
				m = (r + l) / 2;
				if (ch(m, i)) {
					l = m;
				}
				else {
					r = m;
				}
			}
			a[i] = a[l];
		}
	}
	printf("? 1 %d\n", n);
	fflush(stdout);
	scanf("%d", &x);
	printf("Ready!\n");
	printf("%d\n", x);
	for (i = 0; i < n - 1; i++) {
		printf("%d ", a[i]);
	}
	printf("%d\n", a[n - 1]);
	fflush(stdout);
	//scanf("%d", &x);
	return;
}

int main() {
	/*#ifdef _DEBUG
		freopen("input.txt", "rt", stdin);
		freopen("output.txt", "wt", stdout);
	#endif*/
	scanf("%d", &n);
	solve();
	return 0;
}
