QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#376428 | #2526. Imprecise Computer | FOY# | WA | 152ms | 27312kb | Python3 | 183b | 2024-04-04 09:49:26 | 2024-04-04 09:49:27 |
Judging History
answer
n = int(input())
a = [int(i) for i in input().split()]
good = True
for i in a:
if i > 2: good = False
if sum(a)%2 == 1: good = False
if good: print('YES')
else: print('NO')
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 11ms
memory: 9952kb
input:
10 1 2 3 3 3 3 2 1 2 2
output:
NO
result:
ok single line: 'NO'
Test #2:
score: 0
Accepted
time: 11ms
memory: 10024kb
input:
10 0 0 0 0 0 0 0 0 0 1
output:
NO
result:
ok single line: 'NO'
Test #3:
score: 0
Accepted
time: 7ms
memory: 9928kb
input:
10 0 1 0 1 0 1 0 1 0 1
output:
NO
result:
ok single line: 'NO'
Test #4:
score: 0
Accepted
time: 7ms
memory: 9908kb
input:
10 1 0 1 0 1 0 1 0 1 0
output:
NO
result:
ok single line: 'NO'
Test #5:
score: 0
Accepted
time: 7ms
memory: 9940kb
input:
10 1 2 2 2 2 2 2 2 0 1
output:
YES
result:
ok single line: 'YES'
Test #6:
score: 0
Accepted
time: 12ms
memory: 10040kb
input:
10 1 2 2 2 2 2 2 2 0 0
output:
NO
result:
ok single line: 'NO'
Test #7:
score: 0
Accepted
time: 139ms
memory: 27208kb
input:
1000000 0 1 2 1 0 1 2 1 0 1 1 1 0 0 1 0 1 1 1 0 1 0 0 0 0 1 1 1 1 0 1 0 1 0 1 1 0 1 2 0 0 1 1 2 2 0 2 0 2 1 1 0 2 2 0 0 2 1 0 0 0 1 0 2 1 1 1 0 1 0 1 1 1 0 1 1 1 2 1 0 0 0 1 0 1 0 0 1 0 1 1 0 1 1 0 2 2 1 1 0 2 0 2 2 1 1 1 0 1 2 1 0 1 0 1 0 0 1 1 0 0 1 2 0 2 1 1 1 0 1 0 1 0 0 0 0 0 1 2 1 1 0 0 1 0 1 ...
output:
NO
result:
ok single line: 'NO'
Test #8:
score: 0
Accepted
time: 148ms
memory: 27212kb
input:
1000000 1 0 0 0 2 0 2 2 1 1 0 2 0 0 0 1 0 1 1 1 2 2 2 2 1 0 0 1 2 1 1 0 0 0 2 0 0 0 2 2 2 1 1 0 0 0 0 1 0 0 0 0 1 1 0 1 1 0 0 1 0 0 2 1 1 1 0 0 0 1 2 2 0 0 0 0 2 2 2 1 1 0 0 1 0 1 1 1 0 2 1 1 0 2 1 1 1 1 1 0 0 0 1 2 1 1 1 1 1 0 1 2 2 0 2 1 1 0 2 0 0 1 1 2 2 2 0 1 1 2 0 0 0 0 1 0 0 0 0 1 0 0 1 0 1 2 ...
output:
NO
result:
ok single line: 'NO'
Test #9:
score: 0
Accepted
time: 129ms
memory: 27212kb
input:
1000000 1 2 0 0 0 1 1 1 0 1 2 2 2 0 0 1 0 1 2 1 0 0 0 0 0 1 1 1 0 1 0 1 1 1 2 0 1 0 1 1 1 0 2 2 2 1 0 1 1 1 2 2 0 0 0 0 0 0 2 0 0 1 0 0 1 2 0 2 0 1 0 0 1 1 0 1 1 0 1 0 2 2 0 1 0 0 0 0 0 1 1 1 0 2 0 2 2 0 1 1 0 1 0 1 1 0 0 1 0 0 0 2 2 2 1 0 1 2 1 1 0 0 2 0 1 1 2 2 2 1 1 0 2 1 0 1 1 0 1 1 0 0 1 0 2 0 ...
output:
YES
result:
ok single line: 'YES'
Test #10:
score: 0
Accepted
time: 149ms
memory: 27232kb
input:
1000000 0 0 0 0 0 1 2 2 2 1 1 1 0 1 0 2 1 0 0 1 0 1 0 0 0 1 0 0 1 0 0 0 1 2 0 2 2 2 0 0 0 0 0 2 0 1 0 1 0 2 0 0 2 2 2 0 1 0 1 0 0 0 2 0 0 1 0 0 1 1 1 0 1 1 0 2 1 1 2 1 1 1 1 2 1 1 0 0 1 0 1 2 2 1 0 0 0 0 1 0 1 1 0 2 1 1 2 1 1 1 0 0 1 2 2 1 1 1 1 0 2 2 2 2 1 1 2 1 0 0 1 1 1 2 1 1 2 1 0 0 0 0 0 0 0 1 ...
output:
NO
result:
ok single line: 'NO'
Test #11:
score: 0
Accepted
time: 131ms
memory: 27192kb
input:
1000000 1 1 1 0 2 2 2 0 0 1 0 0 0 1 0 1 0 1 0 1 1 2 0 2 2 0 0 1 1 0 2 1 0 1 0 1 0 1 0 2 2 0 1 0 1 0 2 1 0 0 0 0 1 1 0 1 0 1 0 0 0 1 1 1 0 0 1 1 0 1 1 1 1 1 0 0 1 1 1 2 0 1 0 0 1 0 1 1 1 1 0 1 0 1 2 0 2 1 0 1 0 1 0 0 0 1 0 1 1 0 1 0 0 0 1 1 0 0 1 0 2 1 1 0 1 0 1 1 0 1 1 0 1 0 0 1 0 1 2 2 2 2 1 1 2 0 ...
output:
YES
result:
ok single line: 'YES'
Test #12:
score: 0
Accepted
time: 11ms
memory: 10032kb
input:
10 2 1 1 1 1 1 1 1 1 1
output:
NO
result:
ok single line: 'NO'
Test #13:
score: 0
Accepted
time: 119ms
memory: 27196kb
input:
1000000 1 2 0 0 1 1 1 0 1 2 1 0 0 1 0 1 0 1 2 2 0 0 1 1 0 1 1 2 0 1 0 1 0 2 2 2 2 0 2 0 2 1 1 0 1 1 1 0 1 0 0 2 1 0 0 1 1 0 1 0 1 1 2 0 1 1 0 1 0 0 1 1 0 1 2 0 0 1 0 0 1 1 0 0 1 2 1 0 0 0 0 1 1 1 0 1 1 1 1 0 0 2 0 0 2 1 0 1 1 0 0 1 1 1 0 0 1 1 2 1 1 1 1 0 2 0 1 1 1 0 0 0 0 0 0 1 2 1 1 0 2 1 0 0 1 0 ...
output:
YES
result:
ok single line: 'YES'
Test #14:
score: 0
Accepted
time: 152ms
memory: 27312kb
input:
1000000 1 0 0 0 2 0 0 1 1 1 1 0 1 1 0 1 0 1 0 1 1 0 0 1 1 1 0 1 1 0 1 2 0 1 0 0 0 1 2 0 1 1 2 1 1 0 1 1 2 2 1 1 2 2 1 0 1 1 1 0 0 2 2 2 1 0 1 2 2 0 0 0 1 1 1 0 0 0 0 1 0 0 0 2 1 1 1 1 0 1 1 2 0 1 1 0 1 1 2 2 2 0 2 1 1 1 1 2 1 0 1 1 0 1 0 1 1 0 0 2 0 0 0 2 2 0 2 1 1 0 0 2 1 1 2 1 0 1 1 1 1 0 1 0 0 0 ...
output:
NO
result:
ok single line: 'NO'
Test #15:
score: -100
Wrong Answer
time: 144ms
memory: 27208kb
input:
1000000 1 2 2 0 0 1 0 1 2 1 1 0 2 1 0 1 1 1 1 0 1 1 0 0 1 0 2 1 1 1 1 1 0 1 1 1 0 1 0 0 0 1 2 0 1 0 1 2 1 1 0 0 0 1 1 2 0 1 1 2 1 0 1 0 0 2 1 0 1 1 1 1 1 2 0 0 2 1 1 2 1 1 0 0 1 1 0 0 1 0 0 0 0 0 0 0 0 1 0 1 0 0 1 1 0 0 1 2 0 0 0 0 0 1 1 1 1 1 0 0 0 1 0 0 1 1 1 1 2 0 1 0 0 0 1 1 1 0 0 2 1 0 0 1 0 0 ...
output:
YES
result:
wrong answer 1st lines differ - expected: 'NO', found: 'YES'