結果

問題 No.88 次はどっちだ
ユーザー kekenx
提出日時 2020-01-31 18:55:01
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 2 ms / 5,000 ms
コード長 410 bytes
コンパイル時間 1,512 ms
コンパイル使用メモリ 168,392 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-09-17 06:56:14
合計ジャッジ時間 2,105 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 11
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>

using namespace std;

int main() {
  string first, second;
  cin >> first;
  if (first == "oda") second = "yukiko";
  else second = "oda";

  int cnt = 0;
  for (int i = 0; i < 8; ++i) {
    string row;
    cin >> row;
    for (int j = 0; j < 8; ++j) {
      if (row[j] != '.') cnt++;
    }
  }

  if (cnt % 2 == 0) cout << first << endl;
  else cout << second << endl;
  return 0;
}
0