#include using namespace std; #define _GLIBCXX_DEBUG #define dump(c) cerr << "> " << #c << " = " << (c) << endl #define all(c) ((c).begin()), ((c).end()) #define rep(i,n) for(int i=0;i v){rep(i,v.size()){if(i num = {0}; array ans = {0}; int x, y; int unUsed; for (int i = 0; i < 10; ++i) { cout << i << " " << i << " " << i << " " << i << endl; cin >> x >> y; if (x==0 && y==0){ unUsed = i; }else{ num[i] = false; } } for (int i = 0; i < 10; ++i) { cout << i << " " << unUsed << " " << unUsed << " " << unUsed << endl; cin >> x >> y; if (x == 1){ ans[0] = i; break; } } for (int i = 0; i < 10; ++i) { cout << ans[0] << " " << i << " " << unUsed << " " << unUsed << endl; cin >> x >> y; if (x == 2){ ans[1] = i; break; } } for (int i = 0; i < 10; ++i) { cout << ans[0] << " " << ans[1] << " " << i << " " << unUsed << endl; cin >> x >> y; if (x == 3){ ans[2] = i; break; } } for (int i = 0; i < 10; ++i) { cout << ans[0] << " " << ans[1] << " " << ans[2] << " " << i << endl; cin >> x >> y; if (x == 4){ ans[3] = i; break; } } return 0; }