#include<iostream>
#include<vector>
#include<algorithm>
#include<string>
#include<cstdio>
#include<set>

using namespace std;
typedef long long ll;

int main()
{
	//freopen("video.in", "r", stdin);
	//freopen("video.out", "w", stdout);
	ll n;
	cin >> n;
	ll h = 1;
	vector<ll>ct;
	vector<ll>used;
	vector<ll>a(1, 1);
	ll i = 1;
	while (i != n)
	{
		cout << "? " << 1 << " " << i + 1 << endl;
		cout.flush();
		ll p;
		cin >> p;
		if (p > h)
		{
			a.push_back(h + 1);
			h++;
			i++;
		}
		else
		{
			if (h == 1)
			{
				a.push_back(1);
				i++;
				continue;
			}
			ll y = 1, fl = h * (h + 1) / 2, fll = 0;
			used.clear();
			used.resize(h);
			for (int j = i - 1; j >= 0; j--)
				if (used[a[j] - 1] == 0)
				{
					cout << "? " << j + 1 << " " << i + 1 << endl;
					cout.flush();
					cin >> p;
					if (p == y)
					{
						a.push_back(a[j]);
						break;
					}
					else
					{
						used[a[j] - 1]++;
						y++;
						fl-= a[j];
						fll++;
						if (fll + 1 == h)
						{
							a.push_back(fl);
							break;
						}
					}
				}
			i++;
		}
	}
	cout << "Ready!" << endl << h << endl;
	for (int i = 0; i < n; i++)
		cout << a[i] << " ";
	cout.flush();
	return 0;
}