#include using namespace std; #define F first #define S second #define R cin>> #define Z class #define ll long long #define ln cout<=0;i--) #define REP(i,m,n) for(ll i=(ll)(m);i<(ll)(n);i++) #define rep(i,n) REP(i,0,n) #define tr(it,c) for(iter(c) it=(c).begin();it!=(c).end();it++) templatevoid pr(A a){cout<void pr(A a,B b){cout<void pr(A a,B b,C c){cout<void pr(A a,B b,C c,D d){cout<void PR(A a,ll n){rep(i,n){if(i)cout<<' ';cout<=0&&x=0&&y P; void Main() { ll n,x; R n; vector v; REP(i,1,n+1) v.pb(i); while(v.size()>3) { vector g; for(int i=0; i+1=3) { pr("?",v[1],v[2]); R x; if(x==v[2]) swap(v[1],v[2]); pr("?",v[0],v[1]); R x; if(x==v[1]) swap(v[0],v[1]); } if(v[0]%2) { if(v[0]+1<=n&&v[1]!=v[0]+1) { pr("?",v[1],v[0]+1); R x; pr("!",x); } else pr("!",v[1]); } else if(v[1]!=v[0]-1) { pr("?",v[1],v[0]-1); R x; pr("!",x); } else pr("!",v[1]); } int main(){Main();return 0;}