QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#765176 | #8057. Best Carry Player 4 | yangjl | WA | 12ms | 10612kb | Python3 | 381b | 2024-11-20 12:53:23 | 2024-11-20 12:53:23 |
Judging History
answer
t=int(input())
def ilist():
return list(map(int,input().split()))
for line in range(t):
m=int(input())
a=ilist()
b=ilist()
ans=0
for i in range(1,m):
tmp=min(a[i],b[m-i])
a[i]-=tmp
b[m-i]-=tmp
ans+=tmp
if ans:
for i in range(m-1):
ans+=min(a[i],b[m-1-i])
print(ans)
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 0
Wrong Answer
time: 12ms
memory: 10612kb
input:
5 2 1 2 3 4 3 1 0 1 0 1 0 4 1 0 0 1 1 1 1 1 5 123456 114514 1919810 233333 234567 20050815 998244353 0 0 0 10 5 3 5 3 2 4 2 4 1 5 9 9 8 2 4 4 3 5 3 0
output:
3 1 2 467900 26
result:
wrong answer 1st numbers differ - expected: '5', found: '3'