正文
增加 1 行删除 6 行
17 行未改动18192021222324252627288 行未改动373839404142434445464725 行未改动737475767778798017 行未改动最后回答区间 $[l_x,r_y]$ 即可。```cpp#include <bits/stdc++.h>// #define int long long#define lint long long// #define endl '\n'using namespace std;const int N = 1e5+5;struct node{8 行未改动signed main(){ios::sync_with_stdio(0);cin.tie(0);// freopen("app.in","r",stdin);// freopen("app.out","w",stdout);cin >> n;for(int i = 1; i <= n; i++){cout << "? " << i << " " << i << endl;25 行未改动if(v[l].b == input) r = i;}}cout << "! " << v[l].l << " " << v[r].r << endl;return 0;}```17 行未改动1819202122232425268 行未改动353637383940414225 行未改动686970717273747517 行未改动最后回答区间 $[l_x,r_y]$ 即可。```cpp#include <bits/stdc++.h>#define lint long longusing namespace std;const int N = 1e5+5;struct node{8 行未改动signed main(){ios::sync_with_stdio(0);cin.tie(0);cin >> n;for(int i = 1; i <= n; i++){cout << "? " << i << " " << i << endl;25 行未改动if(v[l].b == input) r = i;}}cout << "! " << v[l].l << " " << v[r].r << endl;return 0;}```