結果
| 問題 | No.601 Midpoint Erase |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-10-21 23:05:03 |
| 言語 | C++14 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 50 ms / 2,000 ms |
| コード長 | 547 bytes |
| 記録 | |
| コンパイル時間 | 902 ms |
| コンパイル使用メモリ | 181,044 KB |
| 実行使用メモリ | 6,144 KB |
| 最終ジャッジ日時 | 2026-03-24 01:58:52 |
| 合計ジャッジ時間 | 2,739 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge1_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 23 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
int main() {
int n;
cin>>n;
int cnt[4];
for (int i=0; i<4; i++) cnt[i] = 0;
for (int i=0; i<n; i++) {
int x, y;
cin>>x>>y;
if (x % 2 == 0) {
if (y % 2 == 0) {
++cnt[0];
} else {
++cnt[1];
}
} else {
if (y % 2 == 0) {
++cnt[2];
} else {
++cnt[3];
}
}
}
int sum = 0;
for (int i=0; i<4; i++) sum += cnt[i] / 2;
if (sum % 2 == 1) {
cout<<"Alice"<<endl;
} else {
cout<<"Bob"<<endl;
}
}