#include <string>
#include <map>
#include <set>
#include <iomanip>
#include <algorithm>
#include <cmath>
using namespace std;

#ifdef _DEBUG
#include <iostream>
//ifstream cin("input.txt");
//ofstream cout("output.txt");
#else
#include <iostream>
//ifstream cin("video.in");
//ofstream cout("video.out");
#endif

int x;
int a[3000];

int main() {
	cin >> x;
	a[0] = 1;
	bool p = false;
	int ans = 0;
	cout << "? 1 " << x << endl;
	cout.flush();
	cin >> ans;
	int res = 1;
	for (int i = 1; i < x; i++) {
		cout << "? 1 " << i + 1 << endl;
		cout.flush();
		int nw;
		cin >> nw;
		if (nw == res) {
			set < int > s;
			for (int j = i - 1; j >= 0; j--) {
				if (s.count(a[j]) == 0) {
					s.insert(a[j]);
					cout << "? " << j + 1 << ' ' << i + 1 << endl;
					cout.flush();
					int kek = 0;
					cin >> kek;
					cout << "? " << j + 2 << ' ' << i + 1 << endl;
					cout.flush();
					int mem = 0;
					cin >> mem;
					if (kek == mem) {
						a[i] = a[j];
						break;
					}
				}
			}
		}
		else {

			a[i] = a[i - 1] == 2 ? 1 : 2;

			res = nw;
		}
	}
	cout << "Ready!" << endl;
	cout.flush();
	cout << ans << endl;
	cout.flush();
	for (int i = 0; i < x; i++)
		cout << a[i] << ' ';
	cout.flush();
#ifdef _DEBUG
	system("pause");
#endif
	return 0;
}