結果

問題 No.1183 コイン遊び
ユーザー pluto77pluto77
提出日時 2020-09-29 10:43:16
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 979 ms / 2,000 ms
コード長 264 bytes
コンパイル時間 401 ms
コンパイル使用メモリ 10,652 KB
実行使用メモリ 42,604 KB
最終ジャッジ日時 2023-09-16 15:13:00
合計ジャッジ時間 25,983 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 18 ms
7,800 KB
testcase_01 AC 16 ms
7,696 KB
testcase_02 AC 16 ms
7,760 KB
testcase_03 AC 16 ms
7,892 KB
testcase_04 AC 17 ms
7,784 KB
testcase_05 AC 16 ms
7,768 KB
testcase_06 AC 16 ms
7,788 KB
testcase_07 AC 17 ms
7,844 KB
testcase_08 AC 16 ms
7,916 KB
testcase_09 AC 17 ms
7,708 KB
testcase_10 AC 36 ms
8,536 KB
testcase_11 AC 73 ms
10,056 KB
testcase_12 AC 590 ms
29,052 KB
testcase_13 AC 554 ms
26,724 KB
testcase_14 AC 917 ms
39,196 KB
testcase_15 AC 940 ms
41,476 KB
testcase_16 AC 964 ms
42,192 KB
testcase_17 AC 944 ms
41,704 KB
testcase_18 AC 945 ms
41,688 KB
testcase_19 AC 947 ms
41,820 KB
testcase_20 AC 977 ms
41,728 KB
testcase_21 AC 891 ms
41,872 KB
testcase_22 AC 896 ms
41,800 KB
testcase_23 AC 923 ms
41,556 KB
testcase_24 AC 927 ms
41,764 KB
testcase_25 AC 941 ms
41,624 KB
testcase_26 AC 945 ms
42,604 KB
testcase_27 AC 971 ms
41,556 KB
testcase_28 AC 942 ms
41,732 KB
testcase_29 AC 890 ms
42,340 KB
testcase_30 AC 979 ms
41,636 KB
testcase_31 AC 940 ms
41,720 KB
testcase_32 AC 975 ms
41,684 KB
testcase_33 AC 948 ms
41,700 KB
testcase_34 AC 948 ms
41,820 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#yuki1183
n=int(input())
a=[0]+list(map(int,input().split()))
b=[0]+list(map(int,input().split()))
c=[]
for i in range(n):
 c.append(a[i]^a[i+1])
d=[]
for i in range(n):
 d.append(b[i]^b[i+1])
diff=0
for i in range(n):
 if c[i]!=d[i]:
  diff+=1
print((diff+1)//2)
0