結果

問題 No.717 ファッションへのこだわり
ユーザー MaboyMaboy
提出日時 2021-06-22 01:03:58
言語 Swift
(5.10.0)
結果
AC  
実行時間 23 ms / 2,000 ms
コード長 333 bytes
コンパイル時間 2,198 ms
コンパイル使用メモリ 175,804 KB
実行使用メモリ 14,892 KB
最終ジャッジ日時 2023-09-05 02:05:11
合計ジャッジ時間 3,312 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 7 ms
14,472 KB
testcase_01 AC 7 ms
14,356 KB
testcase_02 AC 7 ms
14,476 KB
testcase_03 AC 7 ms
14,892 KB
testcase_04 AC 6 ms
14,572 KB
testcase_05 AC 7 ms
14,476 KB
testcase_06 AC 8 ms
14,364 KB
testcase_07 AC 14 ms
14,348 KB
testcase_08 AC 19 ms
14,548 KB
testcase_09 AC 23 ms
14,464 KB
testcase_10 AC 13 ms
14,620 KB
testcase_11 AC 14 ms
14,352 KB
testcase_12 AC 17 ms
14,512 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import Foundation

let n = readLine()!.split(separator: " ").map{Int($0)!}
var t = readLine()!
var b = readLine()!
var ta = t.count - t.replacingOccurrences(of: "A", with: "").count
var tb = t.count - ta
var ba = b.count - b.replacingOccurrences(of: "A", with: "").count
var bb = b.count - ba

print([ta,ba].min()! + [tb,bb].min()!)
0