結果

問題 No.717 ファッションへのこだわり
ユーザー ThetaTheta
提出日時 2022-10-18 15:40:49
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 20 ms / 2,000 ms
コード長 279 bytes
コンパイル時間 197 ms
コンパイル使用メモリ 10,680 KB
実行使用メモリ 8,488 KB
最終ジャッジ日時 2023-09-11 08:56:59
合計ジャッジ時間 1,342 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 18 ms
8,388 KB
testcase_01 AC 19 ms
8,388 KB
testcase_02 AC 19 ms
8,356 KB
testcase_03 AC 19 ms
8,376 KB
testcase_04 AC 19 ms
8,420 KB
testcase_05 AC 18 ms
8,364 KB
testcase_06 AC 18 ms
8,404 KB
testcase_07 AC 19 ms
8,340 KB
testcase_08 AC 20 ms
8,396 KB
testcase_09 AC 20 ms
8,304 KB
testcase_10 AC 19 ms
8,300 KB
testcase_11 AC 19 ms
8,360 KB
testcase_12 AC 20 ms
8,488 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from collections import Counter


def main():
    input()
    S = input()
    T = input()
    s_counter = Counter(S)
    t_counter = Counter(T)
    print(min(s_counter["A"], t_counter["A"])
          + min(s_counter["B"], t_counter["B"]))


if __name__ == "__main__":
    main()
0