結果

問題 No.601 Midpoint Erase
ユーザー Kutimoti_TKutimoti_T
提出日時 2018-06-05 19:49:00
言語 C++11
(gcc 11.4.0)
結果
WA  
実行時間 -
コード長 442 bytes
コンパイル時間 1,239 ms
コンパイル使用メモリ 144,764 KB
実行使用メモリ 4,388 KB
最終ジャッジ日時 2023-09-12 22:33:21
合計ジャッジ時間 2,864 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 1 ms
4,380 KB
testcase_02 AC 2 ms
4,380 KB
testcase_03 WA -
testcase_04 AC 52 ms
4,380 KB
testcase_05 WA -
testcase_06 AC 21 ms
4,380 KB
testcase_07 WA -
testcase_08 AC 42 ms
4,376 KB
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 AC 2 ms
4,384 KB
testcase_14 AC 1 ms
4,380 KB
testcase_15 WA -
testcase_16 AC 1 ms
4,380 KB
testcase_17 AC 1 ms
4,380 KB
testcase_18 WA -
testcase_19 AC 1 ms
4,380 KB
testcase_20 WA -
testcase_21 AC 1 ms
4,380 KB
testcase_22 AC 1 ms
4,380 KB
testcase_23 AC 1 ms
4,380 KB
testcase_24 AC 1 ms
4,380 KB
testcase_25 AC 2 ms
4,380 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;
using i64 = long long;
#define rep(i,s,e) for(int (i) = (s);(i) <= (e);(i)++)
int main(){
  int N;
  cin >> N;
  vector<int> c(4,0);
  for(int i = 0;i < N;i++){
    int x,y;
    cin >> x >> y;
    x &= 1;
    y &= 1;
    c[x | (y << 1)]++;
  }
  int sum = 0;
  for(int i = 0;i < 4;i++){
    sum += c[i];
  }
  if(sum & 1){
    cout << "Alice" << endl;
  }
  else{
    cout << "Bob" << endl;
  }
}
0