#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; typedef long long ll; typedef pair P; long long int INF = 3e18; double Pi = 3.1415926535897932384626; vector G[500005]; vector

tree[500010]; priority_queue pql; priority_queue

pqp; //big priority queue priority_queue ,greater > pqls; priority_queue ,greater

> pqps; //small priority queue //top pop int dx[8]={1,0,-1,0,1,1,-1,-1}; int dy[8]={0,1,0,-1,1,-1,-1,1}; char dir[] = "DRUL"; //ll bit[500005]; //↓,→,↑,← #define p(x) cout<> c; return c; } int main(){ cin >> n; one = quest(1,2); two = 3 - one; ll look = 3; while(1){ if(look > n)break; ll ans = quest(two,look); if(ans == two){ look++; continue; }else{ two = look; ans = quest(one,look); if(ans == one){ look++; continue; }else{ swap(one,two); look++; } } } pe("!");p(two); return 0; }