#include using namespace std; int main(){ int N,buf; int odd[1000] = {}; int even[1000] = {}; int A[501]; char ans[500]; bool flag=true; cin >> N; for(int i=0;i<=N;i++) A[i] = i; for(int i=1;i<=(N/2)*2;i++) even[i-1] = i; for(int i=1;i<=(N/2)*2-(N-1)%2*2;i++) odd[i-1] = i+1; while(flag){ flag = false; cout << "? "; for(int i=0;i<2*N;i++) cout << A[even[i]] << " "; cout << endl; for(int i=0;i> ans[i]; if(ans[i] == '>'){ buf = A[even[2*i]]; A[even[2*i]] = A[even[2*i+1]]; A[even[2*i+1]] = buf; flag = true; } } cout << "? "; for(int i=0;i<2*N;i++) cout << A[odd[i]] << " "; cout << endl; for(int i=0;i> ans[i]; if(ans[i] == '>'){ buf = A[odd[2*i]]; A[odd[2*i]] = A[odd[2*i+1]]; A[odd[2*i+1]] = buf; flag = buf; } } } cout << "! "; for(int i=1;i<=N;i++) cout << A[i] << " "; cout << endl; return 0; }