結果

問題 No.1183 コイン遊び
ユーザー godcitygodcity
提出日時 2020-10-25 08:07:38
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 577 ms / 2,000 ms
コード長 274 bytes
コンパイル時間 168 ms
コンパイル使用メモリ 10,624 KB
実行使用メモリ 34,468 KB
最終ジャッジ日時 2023-09-28 22:14:06
合計ジャッジ時間 16,787 ms
ジャッジサーバーID
(参考情報)
judge14 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,788 KB
testcase_01 AC 16 ms
7,876 KB
testcase_02 AC 16 ms
7,696 KB
testcase_03 AC 16 ms
7,748 KB
testcase_04 AC 16 ms
7,804 KB
testcase_05 AC 16 ms
7,824 KB
testcase_06 AC 16 ms
7,768 KB
testcase_07 AC 16 ms
7,804 KB
testcase_08 AC 16 ms
7,764 KB
testcase_09 AC 17 ms
7,884 KB
testcase_10 AC 27 ms
8,712 KB
testcase_11 AC 49 ms
9,612 KB
testcase_12 AC 359 ms
23,828 KB
testcase_13 AC 310 ms
23,832 KB
testcase_14 AC 536 ms
32,176 KB
testcase_15 AC 548 ms
33,432 KB
testcase_16 AC 561 ms
33,148 KB
testcase_17 AC 549 ms
33,216 KB
testcase_18 AC 546 ms
34,468 KB
testcase_19 AC 550 ms
33,344 KB
testcase_20 AC 558 ms
33,220 KB
testcase_21 AC 506 ms
33,348 KB
testcase_22 AC 490 ms
33,152 KB
testcase_23 AC 530 ms
33,196 KB
testcase_24 AC 509 ms
33,296 KB
testcase_25 AC 539 ms
33,288 KB
testcase_26 AC 562 ms
33,588 KB
testcase_27 AC 558 ms
33,288 KB
testcase_28 AC 546 ms
33,404 KB
testcase_29 AC 499 ms
33,192 KB
testcase_30 AC 577 ms
33,356 KB
testcase_31 AC 566 ms
33,876 KB
testcase_32 AC 565 ms
33,216 KB
testcase_33 AC 544 ms
33,336 KB
testcase_34 AC 543 ms
33,332 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
a = list(map(int, input().split()))
b = list(map(int, input().split()))

c = []
same = True
ans = 0
for i in range(n):
    if (a[i] == b[i]):
        same = True
    else:
        if (same == True):
            same = False
            ans += 1

print(ans)
0