結果
| 問題 |
No.601 Midpoint Erase
|
| コンテスト | |
| ユーザー |
CELICA
|
| 提出日時 | 2020-09-06 15:53:38 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 26 ms / 2,000 ms |
| コード長 | 478 bytes |
| コンパイル時間 | 1,598 ms |
| コンパイル使用メモリ | 166,340 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-11-29 07:13:57 |
| 合計ジャッジ時間 | 3,632 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 23 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ul = unsigned long;
int main()
{
ios::sync_with_stdio(false);
cin.tie(nullptr);
int n;
cin >> n;
int oo{ 0 }, oe{ 0 }, ee{ 0 }, eo{ 0 };
for (int i = 0; i < n; ++i)
{
int x, y;
cin >> x >> y;
if (x & 1)
y & 1 ? ++oo : ++oe;
else
y & 1 ? ++eo : ++ee;
}
int nn = oo / 2 + oe / 2 + ee / 2 + eo / 2;
string res = (nn & 1 ? "Alice" : "Bob");
cout << res << "\n";
return 0;
}
CELICA