QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#376413#2526. Imprecise ComputerFOY#WA 4ms9464kbPython3216b2024-04-04 09:39:172024-04-04 09:39:17

Judging History

This is the latest submission verdict.

  • [2024-04-04 09:39:17]
  • Judged
  • Verdict: WA
  • Time: 4ms
  • Memory: 9464kb
  • [2024-04-04 09:39:17]
  • Submitted

answer

n = int(input())
a = [int(v) for i, v in enumerate(input().split())]
a.append(0)

for i in range(n):
    a[i+1] -= a[i]
    a[i+1] = abs(a[i+1])
    a[i] = 0

if a[-1] == 0: print('YES')
else: print('NO')

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 0
Wrong Answer
time: 4ms
memory: 9464kb

input:

10
1 2 3 3 3 3 2 1 2 2

output:

YES

result:

wrong answer 1st lines differ - expected: 'NO', found: 'YES'