結果

問題 No.1183 コイン遊び
ユーザー AndrewKAndrewK
提出日時 2020-08-01 12:40:18
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 676 ms / 2,000 ms
コード長 223 bytes
コンパイル時間 177 ms
コンパイル使用メモリ 10,480 KB
実行使用メモリ 34,564 KB
最終ジャッジ日時 2023-09-22 06:21:35
合計ジャッジ時間 15,629 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,864 KB
testcase_01 AC 16 ms
7,980 KB
testcase_02 AC 16 ms
7,864 KB
testcase_03 AC 16 ms
7,792 KB
testcase_04 AC 15 ms
7,784 KB
testcase_05 AC 15 ms
7,832 KB
testcase_06 AC 15 ms
7,756 KB
testcase_07 AC 15 ms
7,840 KB
testcase_08 AC 17 ms
7,860 KB
testcase_09 AC 17 ms
7,828 KB
testcase_10 AC 27 ms
8,724 KB
testcase_11 AC 51 ms
9,640 KB
testcase_12 AC 390 ms
23,904 KB
testcase_13 AC 337 ms
22,304 KB
testcase_14 AC 553 ms
32,488 KB
testcase_15 AC 606 ms
33,344 KB
testcase_16 AC 592 ms
33,268 KB
testcase_17 AC 604 ms
33,364 KB
testcase_18 AC 597 ms
33,328 KB
testcase_19 AC 598 ms
34,224 KB
testcase_20 AC 610 ms
33,328 KB
testcase_21 AC 461 ms
33,276 KB
testcase_22 AC 464 ms
33,192 KB
testcase_23 AC 676 ms
34,564 KB
testcase_24 AC 472 ms
33,408 KB
testcase_25 AC 594 ms
33,392 KB
testcase_26 AC 616 ms
33,284 KB
testcase_27 AC 604 ms
33,416 KB
testcase_28 AC 593 ms
33,388 KB
testcase_29 AC 459 ms
33,356 KB
testcase_30 AC 604 ms
33,232 KB
testcase_31 AC 588 ms
34,376 KB
testcase_32 AC 599 ms
34,076 KB
testcase_33 AC 591 ms
33,444 KB
testcase_34 AC 599 ms
33,396 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
a = list(map(int, input().split()))
b = list(map(int, input().split()))
ans = 0
if a[0] ^ b[0]:
    ans += 1
for i in range(1, n):
    if (a[i] != b[i]) and (a[i-1] == b[i-1]):
        ans += 1

print(ans)
0