結果
問題 |
No.2629 A replace B replace C
|
ユーザー |
|
提出日時 | 2024-02-16 22:29:11 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 246 bytes |
コンパイル時間 | 366 ms |
コンパイル使用メモリ | 82,136 KB |
実行使用メモリ | 56,432 KB |
最終ジャッジ日時 | 2024-09-28 21:02:58 |
合計ジャッジ時間 | 4,637 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 5 |
other | AC * 44 WA * 17 |
ソースコード
N = int(input()) S = input() T = input() sa = S.count('A') sb = S.count('B') sc = S.count('C') ta = T.count('A') tb = T.count('B') tc = T.count('C') print("Yes" if sb == tb and sa >= ta and sa + ta == sc + tc and (sb if sa > ta else 1) else "No")