結果
問題 | No.1149 色塗りゲーム |
ユーザー | fastmath |
提出日時 | 2020-08-12 19:42:35 |
言語 | C++14 (gcc 12.3.0 + boost 1.83.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 1,343 bytes |
コンパイル時間 | 1,515 ms |
コンパイル使用メモリ | 165,836 KB |
実行使用メモリ | 24,504 KB |
平均クエリ数 | 14.42 |
最終ジャッジ日時 | 2023-09-24 05:31:32 |
合計ジャッジ時間 | 9,757 ms |
ジャッジサーバーID (参考情報) |
judge11 / judge13 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 43 ms
24,324 KB |
testcase_01 | AC | 38 ms
23,640 KB |
testcase_02 | RE | - |
testcase_03 | AC | 39 ms
23,520 KB |
testcase_04 | RE | - |
testcase_05 | AC | 40 ms
24,024 KB |
testcase_06 | RE | - |
testcase_07 | AC | 40 ms
24,048 KB |
testcase_08 | RE | - |
testcase_09 | AC | 40 ms
24,360 KB |
testcase_10 | AC | 42 ms
23,652 KB |
testcase_11 | RE | - |
testcase_12 | AC | 41 ms
23,412 KB |
testcase_13 | RE | - |
testcase_14 | AC | 42 ms
23,652 KB |
testcase_15 | RE | - |
testcase_16 | AC | 43 ms
24,372 KB |
testcase_17 | RE | - |
testcase_18 | AC | 43 ms
23,520 KB |
testcase_19 | RE | - |
testcase_20 | AC | 42 ms
24,372 KB |
testcase_21 | RE | - |
testcase_22 | AC | 44 ms
23,652 KB |
testcase_23 | RE | - |
testcase_24 | AC | 45 ms
24,024 KB |
testcase_25 | RE | - |
testcase_26 | AC | 43 ms
23,412 KB |
testcase_27 | RE | - |
testcase_28 | AC | 45 ms
23,388 KB |
testcase_29 | RE | - |
testcase_30 | RE | - |
testcase_31 | AC | 81 ms
24,252 KB |
testcase_32 | RE | - |
testcase_33 | AC | 83 ms
23,640 KB |
testcase_34 | RE | - |
testcase_35 | AC | 83 ms
24,264 KB |
testcase_36 | RE | - |
testcase_37 | AC | 90 ms
23,508 KB |
testcase_38 | RE | - |
testcase_39 | AC | 91 ms
23,796 KB |
testcase_40 | RE | - |
testcase_41 | AC | 92 ms
23,532 KB |
testcase_42 | RE | - |
testcase_43 | AC | 94 ms
23,652 KB |
testcase_44 | RE | - |
testcase_45 | AC | 104 ms
24,324 KB |
testcase_46 | RE | - |
testcase_47 | AC | 104 ms
24,012 KB |
testcase_48 | RE | - |
testcase_49 | AC | 113 ms
23,844 KB |
ソースコード
#include<bits/stdc++.h> using namespace std; #define int long long #define ii pair <int, int> #define app push_back #define all(a) a.begin(), a.end() #define bp __builtin_popcountll #define ll long long #define mp make_pair #define f first #define s second #define Time (double)clock()/CLOCKS_PER_SEC #define debug(x) std::cout << #x << ": " << x << '\n'; signed main() { int n; cin >> n; if (n % 2 == 0) { cout << 2 << ' ' << n/2 << endl; while (1) { int tp; cin >> tp; if (tp == 0) exit(0); assert(tp == 3); int t, p; cin >> t >> p; int sh = n/2+1; if (p < n/2) { cout << t << ' ' << p + sh << endl; } else { cout << t << ' ' << p - sh << endl; } } } else { cout << 1 << ' ' << n/2 + 1 << endl; while (1) { int tp; cin >> tp; if (tp == 0) exit(0); assert(tp == 3); int t, p; cin >> t >> p; if (p < n/2) { cout << t << ' ' << p + n/2 << endl; } else { cout << t << ' ' << p - n/2 << endl; } } } }