結果

問題 No.2196 Pair Bonus
ユーザー tassei903tassei903
提出日時 2023-01-20 21:43:00
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 218 ms / 2,000 ms
コード長 562 bytes
コンパイル時間 308 ms
コンパイル使用メモリ 87,128 KB
実行使用メモリ 141,456 KB
最終ジャッジ日時 2023-09-05 13:57:40
合計ジャッジ時間 3,891 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 76 ms
71,168 KB
testcase_01 AC 74 ms
71,324 KB
testcase_02 AC 74 ms
71,324 KB
testcase_03 AC 218 ms
137,596 KB
testcase_04 AC 215 ms
137,712 KB
testcase_05 AC 77 ms
75,956 KB
testcase_06 AC 77 ms
76,104 KB
testcase_07 AC 83 ms
75,864 KB
testcase_08 AC 117 ms
85,492 KB
testcase_09 AC 217 ms
141,456 KB
testcase_10 AC 170 ms
114,520 KB
testcase_11 AC 121 ms
88,232 KB
testcase_12 AC 190 ms
117,008 KB
testcase_13 AC 78 ms
75,824 KB
testcase_14 AC 103 ms
79,280 KB
testcase_15 AC 78 ms
75,772 KB
testcase_16 AC 203 ms
128,088 KB
testcase_17 AC 83 ms
76,740 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = lambda :sys.stdin.readline()[:-1]
ni = lambda :int(input())
na = lambda :list(map(int,input().split()))
yes = lambda :print("yes");Yes = lambda :print("Yes");YES = lambda : print("YES")
no = lambda :print("no");No = lambda :print("No");NO = lambda : print("NO")
#######################################################################

n = ni()
a = na()
b = na()
x = na()
y = na()
ans = 0
for i in range(n):
    a1,a2 = a[i*2:i*2+2]
    b1,b2 = b[i*2:i*2+2]
    X = x[i]
    Y = y[i]
    ans += max(a1+a2+X,b1+b2+X,a1+b2+Y,b1+a2+Y)

print(ans)
0