#include using namespace std; int T, N; int Money; int L[19]; int S[19], P[19], R[19]; int main() { // 最初の入力 cin >> T >> N >> Money; T -= 30; cout<<"2 2"<> Money; for (int i = 1; i <= N; i++) cin >> S[i]; for (int i = 1; i <= N; i++) cin >> P[i]; for (int i = 1; i <= N; i++) cin >> R[i]; cout<<"2 1"<> Money; for (int i = 1; i <= N; i++) cin >> S[i]; for (int i = 1; i <= N; i++) cin >> P[i]; for (int i = 1; i <= N; i++) cin >> R[i]; for(int i=0;i<28;i++){ for (int i = 1; i <= N; i++) L[i] = 3-R[i]; cout << 1; for (int i = 1; i <= N; i++) cout << " " << L[i]; cout << endl; cin >> Money; for (int i = 1; i <= N; i++) cin >> S[i]; for (int i = 1; i <= N; i++) cin >> P[i]; for (int i = 1; i <= N; i++) cin >> R[i]; } // インタラクティブ開始 for (int t = 1; t <= T; t++) { // (あ) 出版社の行動を出力する for (int i = 1; i <= N; i++) L[i] = Money / (500 * N); cout << 1; for (int i = 1; i <= N; i++) cout << " " << L[i]; cout << endl; // (い) 売上部数などを入力する cin >> Money; for (int i = 1; i <= N; i++) cin >> S[i]; for (int i = 1; i <= N; i++) cin >> P[i]; for (int i = 1; i <= N; i++) cin >> R[i]; } return 0; }