結果

問題 No.69 文字を自由に並び替え
ユーザー suzu11201784
提出日時 2020-01-13 19:38:53
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
WA  
実行時間 -
コード長 412 bytes
コンパイル時間 545 ms
コンパイル使用メモリ 55,380 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2024-12-21 14:47:11
合計ジャッジ時間 1,143 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 9 WA * 6
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<iostream>
#include<string>
using namespace std;
#define MAX 100
int ss[MAX];
int main()
{
    
    string A,B;
    cin >> A;
    for (auto a :A ) {
        ss[a]++;
    }
    cin >> B;
    for (auto a : B) {
        ss[a]--;
    }
    for (int i = 0; i < MAX; i++) {
        if (!ss[i]) {
            cout << "YES" << endl;
            return 0;
        }
    }
    cout << "NO" << endl;
    return 0;
}
0