結果
問題 | No.819 Enjapma game |
ユーザー |
|
提出日時 | 2019-04-19 22:39:42 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 391 bytes |
コンパイル時間 | 651 ms |
コンパイル使用メモリ | 71,324 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-09-22 22:41:45 |
合計ジャッジ時間 | 1,631 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 14 WA * 12 |
ソースコード
#include <iostream>#include <algorithm>#include <vector>#include <string>#define REP(i, n) for (int i = 0; i < (n); i++)using namespace std;int main() {int H, W;cin >> H >> W;vector<string> S(H);REP(i, H) cin >> S[i];int a[2] = {};REP(i, H) REP(j, W) {if (S[i][j] == 'o') {a[(i + j) % 2] ^= 1;}}puts(a[0] == 0 && a[1] == 1 ? "NO" : "YES");}