結果

問題 No.3061 uxs hxixtya pyuyn ixc hyixa kxuyn
ユーザー trineutrontrineutron
提出日時 2020-04-01 23:26:46
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 474 bytes
コンパイル時間 1,911 ms
コンパイル使用メモリ 199,288 KB
実行使用メモリ 4,380 KB
最終ジャッジ日時 2023-09-09 20:14:55
合計ジャッジ時間 4,731 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ(β)

テストケース

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

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;

int main() {
    string s;
    getline(cin, s);
    vector<int> even(26), odd(26);
    for (int i = 0; i < s.size(); i++) {
        if (i % 2 == 0) {
            even.at(s.at(i) - 'a')++;
        } else {
            odd.at(s.at(i) - 'a')++;
        }
    }
    for (int i = 0; i < 26; i++) {
        if ((even.at(i) == 0) != (odd.at(i) == 0)) {
            puts("Yes");
            return 0;
        }
    }
    puts("NO");
}
0