結果

問題 No.2209 Flip and Reverse
ユーザー KudeKude
提出日時 2023-02-10 21:30:47
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 186 ms / 2,000 ms
コード長 179 bytes
コンパイル時間 411 ms
コンパイル使用メモリ 86,884 KB
実行使用メモリ 81,680 KB
最終ジャッジ日時 2023-09-21 22:34:10
合計ジャッジ時間 6,915 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 76 ms
71,048 KB
testcase_01 AC 75 ms
71,068 KB
testcase_02 AC 82 ms
71,044 KB
testcase_03 AC 75 ms
71,164 KB
testcase_04 AC 77 ms
71,116 KB
testcase_05 AC 78 ms
71,212 KB
testcase_06 AC 76 ms
71,264 KB
testcase_07 AC 76 ms
71,356 KB
testcase_08 AC 159 ms
81,288 KB
testcase_09 AC 74 ms
71,052 KB
testcase_10 AC 75 ms
71,120 KB
testcase_11 AC 74 ms
71,148 KB
testcase_12 AC 73 ms
71,164 KB
testcase_13 AC 72 ms
70,896 KB
testcase_14 AC 181 ms
81,436 KB
testcase_15 AC 184 ms
81,364 KB
testcase_16 AC 184 ms
81,492 KB
testcase_17 AC 185 ms
81,580 KB
testcase_18 AC 184 ms
81,400 KB
testcase_19 AC 186 ms
81,432 KB
testcase_20 AC 183 ms
81,556 KB
testcase_21 AC 183 ms
81,680 KB
testcase_22 AC 184 ms
81,360 KB
testcase_23 AC 185 ms
81,364 KB
testcase_24 AC 180 ms
81,364 KB
testcase_25 AC 181 ms
81,640 KB
testcase_26 AC 178 ms
81,400 KB
testcase_27 AC 179 ms
81,516 KB
testcase_28 AC 167 ms
81,428 KB
testcase_29 AC 166 ms
81,364 KB
testcase_30 AC 168 ms
81,432 KB
testcase_31 AC 165 ms
81,124 KB
testcase_32 AC 162 ms
81,176 KB
testcase_33 AC 164 ms
81,368 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
s = input()
t = input()
c0 = sum(c0 != c1 for c0, c1 in zip(s, t))
c1 = sum(c0 != c1 for c0, c1 in zip(reversed(s), t))
ans = c0 if c0 % 2 == 0 else c1
print(ans)
0