結果
| 問題 |
No.355 数当てゲーム(2)
|
| コンテスト | |
| ユーザー |
ldsyb
|
| 提出日時 | 2016-04-01 23:56:29 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 1,589 bytes |
| コンパイル時間 | 688 ms |
| コンパイル使用メモリ | 59,576 KB |
| 実行使用メモリ | 25,856 KB |
| 平均クエリ数 | 41.00 |
| 最終ジャッジ日時 | 2024-07-16 09:29:20 |
| 合計ジャッジ時間 | 11,353 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | WA * 52 |
ソースコード
#include <iostream>
#include <algorithm>
using namespace std;
int main(){
int x = 0,y = 0,n[4] = {};
for(int i = 0;i < 10;i++){
cout << i << ' ' << 0 << ' ' << 1 << ' ' << 2 << endl;
cin >> x >> y;
if(x == 1){
n[0] = i;
break;
}else if(x){
cout << i << ' ' << 2 << ' ' << 0 << ' ' << 1 << endl;
cin >> x >> y;
if(x){
n[0] = i;
break;
}
}
}
for(int i = 0;i < 10;i++){
cout << 0 << ' ' << i << ' ' << 1 << ' ' << 2 << endl;
cin >> x >> y;
if(x == 1){
n[1] = i;
break;
}else if(x){
cout << 2 << ' ' << i << ' ' << 0 << ' ' << 1 << endl;
cin >> x >> y;
if(x){
n[1] = i;
break;
}
}
}
for(int i = 0;i < 10;i++){
cout << 1 << ' ' << 0 << ' ' << i << ' ' << 2 << endl;
cin >> x >> y;
if(x == 1){
n[2] = i;
break;
}else if(x){
cout << 0 << ' ' << 2 << ' ' << i << ' ' << 1 << endl;
cin >> x >> y;
if(x){
n[2] = i;
break;
}
}
}
for(int i = 0;i < 10;i++){
cout << 2 << ' ' << 0 << ' ' << 1 << ' ' << i << endl;
cin >> x >> y;
if(x == 1){
n[3] = i;
break;
}else if(x){
cout << 1 << ' ' << 2 << ' ' << 0 << ' ' << i << endl;
cin >> x >> y;
if(x){
n[3] = i;
break;
}
}
}
cout << n[0] << ' ' << n[1] << ' ' << n[2] << ' ' << n[3] << endl;
}
ldsyb