結果
問題 | No.2962 Sum Bomb Bomber |
ユーザー | rieaaddlreiuu |
提出日時 | 2024-12-04 01:10:26 |
言語 | C++14 (gcc 12.3.0 + boost 1.83.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 1,032 bytes |
コンパイル時間 | 1,787 ms |
コンパイル使用メモリ | 166,292 KB |
実行使用メモリ | 25,580 KB |
平均クエリ数 | 33.54 |
最終ジャッジ日時 | 2024-12-04 01:10:38 |
合計ジャッジ時間 | 11,752 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 74 ms
24,952 KB |
testcase_01 | AC | 94 ms
24,904 KB |
testcase_02 | WA | - |
testcase_03 | WA | - |
testcase_04 | WA | - |
testcase_05 | WA | - |
testcase_06 | AC | 80 ms
24,428 KB |
testcase_07 | AC | 99 ms
24,824 KB |
testcase_08 | WA | - |
testcase_09 | WA | - |
testcase_10 | WA | - |
testcase_11 | WA | - |
testcase_12 | WA | - |
testcase_13 | AC | 69 ms
24,824 KB |
testcase_14 | AC | 95 ms
25,208 KB |
testcase_15 | AC | 78 ms
25,208 KB |
testcase_16 | WA | - |
testcase_17 | WA | - |
testcase_18 | WA | - |
testcase_19 | WA | - |
testcase_20 | WA | - |
testcase_21 | AC | 77 ms
24,824 KB |
testcase_22 | WA | - |
testcase_23 | WA | - |
testcase_24 | WA | - |
testcase_25 | AC | 70 ms
25,208 KB |
testcase_26 | WA | - |
testcase_27 | WA | - |
testcase_28 | WA | - |
testcase_29 | WA | - |
testcase_30 | WA | - |
testcase_31 | AC | 69 ms
24,824 KB |
testcase_32 | WA | - |
testcase_33 | WA | - |
testcase_34 | WA | - |
testcase_35 | WA | - |
testcase_36 | WA | - |
testcase_37 | WA | - |
testcase_38 | WA | - |
testcase_39 | WA | - |
testcase_40 | WA | - |
testcase_41 | WA | - |
testcase_42 | WA | - |
testcase_43 | AC | 79 ms
25,208 KB |
testcase_44 | WA | - |
testcase_45 | WA | - |
testcase_46 | WA | - |
testcase_47 | WA | - |
testcase_48 | WA | - |
testcase_49 | WA | - |
testcase_50 | WA | - |
testcase_51 | AC | 70 ms
24,428 KB |
testcase_52 | AC | 69 ms
24,692 KB |
testcase_53 | AC | 70 ms
24,892 KB |
testcase_54 | AC | 78 ms
24,544 KB |
testcase_55 | AC | 78 ms
25,196 KB |
testcase_56 | AC | 86 ms
24,428 KB |
testcase_57 | WA | - |
testcase_58 | WA | - |
testcase_59 | WA | - |
testcase_60 | WA | - |
testcase_61 | WA | - |
testcase_62 | WA | - |
testcase_63 | WA | - |
testcase_64 | WA | - |
ソースコード
#include<bits/stdc++.h> using namespace std; int d(int x,int y){ int result; cout << "1 " << x << " " << y << endl; cin >> result; return result; } int main(){ int min_x,min_y; int N; int d_1,d_2,d_3; cin >> N; int left = -200000000,right = 200000000; int mid = (left+right)/2; d_1 = d(mid-1,0); d_2 = d(mid,0); d_3 = d(mid+1,0); while((d_1 < d_2 && d_2 < d_3) || (d_1 > d_2 && d_2 > d_3)){ if(d_1 < d_2 && d_2 < d_3){ right = mid; } if(d_1 > d_2 && d_2 > d_3){ left = mid; } mid = (left+right)/2; d_1 = d(mid-1,0); d_2 = d(mid,0); d_3 = d(mid+1,0); } min_x = mid; left = -200000000,right = 200000000; mid = (left+right)/2; d_1 = d(0,mid-1); d_2 = d(0,mid); d_3 = d(0,mid+1); while((d_1 < d_2 && d_2 < d_3) || (d_1 > d_2 && d_2 > d_3)){ if(d_1 < d_2 && d_2 < d_3){ right = mid; } if(d_1 > d_2 && d_2 > d_3){ left = mid; } mid = (left+right)/2; d_1 = d(0,mid-1); d_2 = d(0,mid); d_3 = d(0,mid+1); } min_y = mid; cout << "2 " << min_x << " " << min_y << endl; }