Problem:
 Score : 300 points    Problem Statement There are N integers written on a blackboard. The i -th integer is A_i .  Takahashi will repeatedly perform the following operation on these numbers:   Select a pair of integers, A_i and A_j , that have the same parity (that is, both are even or both are odd) and erase them.  Then, write a new integer on the blackboard that is equal to the sum of those integers, A_i+A_j .   Determine whether it is possible to have only one integer on the blackboard.      Constraints  2 ≦ N ≦ 10^5  1 ≦ A_i ≦ 10^9  A_i is an integer.         Input The input is given from Standard Input in the following format:  N  A_1  A_2 … A_N       Output If it is possible to have only one integer on the blackboard, print YES . Otherwise, print NO .        Sample Input 1 3
1 2 3      Sample Output 1 YES  It is possible to have only one integer on the blackboard, as follows:   Erase 1 and 3 from the blackboard, then write 4 . Now, there are two integers on the blackboard: 2 and 4 .  Erase 2 and 4 from the blackboard, then write 6 . Now, there is only one integer on the blackboard: 6 .        Sample Input 2 5
1 2 3 4 5      Sample Output 2 NO

Solution (Python):
import sys
def input(): return sys.stdin.readline().rstrip()
def main():
    _=input()
    A=[int(a) for a in input().split() if int(a)%2==1]
    if len(A)%2:print("NO")
    else:print("YES")

if __name__=='__main__':
    main()

Solution (Python):
import sys
def input(): return sys.stdin.readline().rstrip()
def main():
    _=input()
    A=[int(a) for a in input().split() if int(a)%2==1]
    if len(A)%2:print("NO")
    else:print("YES")

if __name__=='__main__':
    main()

Solution (Python):
n = int(input())
a = [int(x) for x in input().split()]

a_odd = len([x for x in a if x % 2 != 0])


if a_odd % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
import sys

def main():
    def input(): return sys.stdin.readline().rstrip()
    N = int(input())
    A = list(map(int, input().split()))
    cnt = 0
    for i in range(N):
        if A[i] % 2 != 0:
            cnt += 1
    
    print('YES' if cnt % 2 == 0 else 'NO')
if __name__ == '__main__':
    main()

Solution (Python):
import sys

def main():
    N = int(input())
    A = list(map(int, input().split()))
    cnt = 0
    for i in range(N):
        if A[i] % 2 != 0:
            cnt += 1
    
    print('YES' if cnt % 2 == 0 else 'NO')
if __name__ == '__main__':
    main()

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import groupby, accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()
A = LIST()

if sum(x%2==1 for x in A)%2 == 1:
	print("NO")
else:
	print("YES")

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
num=0

for i in range(n):
  if a[i]%2==1:
    num+=1
    
if num%2==0:
  print("YES")
elif num%2==1 and n==num:
  print("YES")
else:
  print("NO")

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
A_even = [num for num in A if num%2 == 0]
A_odd = [num for num in A if num%2 != 0]
e = len(A_even)
o = len(A_odd)

if(o%2 == 0):
    print("YES")
else:
    print("NO")

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

odd_count = 0
for a in A:
    if a % 2 == 1:
        odd_count += 1

if odd_count % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
cnt = 0
for a in A:
    if a%2==1:
        cnt += 1

if cnt%2==0:
    print('YES')
else:
    print('NO')

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
cnt = 0
for a in A:
    if a%2==1:
        cnt += 1

if cnt%2==0:
    print('YES')
else:
    print('NO')

Solution (Python):
n = int(input())
ne = 0
no = 0
a = list(map(int, input().split()))
for ai in a:
    if ai % 2 == 0:
        ne += 1
    else:
        no += 1




odd_rem = no % 2
ne += no // 2







if odd_rem == 1:
    print("NO")
else:
    print("YES")

Solution (Python):

n = int(input())
a = list(map(int,input().split()))

if sum(a) % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
cnt = 0

for i in range(n):
    if a[i]%2 == 1:
        cnt += 1
if cnt%2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
cnt = 0

for i in range(n):
    if a[i]%2 == 1:
        cnt += 1
if cnt%2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
import sys,collections as cl,bisect as bs
sys.setrecursionlimit(100000)
input = sys.stdin.readline
mod = 10**9+7
Max = sys.maxsize
def l(): 
    return list(map(int,input().split()))
def m(): 
    return map(int,input().split())
def onem(): 
    return int(input())
def s(x): 
    a = []
    if len(x) == 0:
        return []
    aa = x[0]
    su = 1
    for i in range(len(x)-1):
        if aa != x[i+1]:
            a.append([aa,su])
            aa = x[i+1]
            su = 1
        else:
            su += 1
    a.append([aa,su])
    return a
def jo(x): 
    return " ".join(map(str,x))
def max2(x): 
    return max(map(max,x))
def In(x,a): 
    k = bs.bisect_left(a,x)
    if k != len(a) and a[k] ==  x:
        return True
    else:
        return False

def pow_k(x, n):
    ans = 1
    while n:
        if n % 2:
            ans *= x
        x *= x
        n >>= 1
    return ans

"""
def nibu(x,n,r):
    ll = 0
    rr = r
    while True:
        mid = (ll+rr)//2

    if rr == mid:
        return ll
    if (ここに評価入れる):
        rr = mid
    else:
        ll = mid+1
"""

n = onem()

a = l()

co = 0

for i in range(n):
    if a[i] % 2 == 1:
        co += 1
print("YES" if co % 2 == 0 else "NO")

Solution (Python):
n = input()
s = list(map(int,input().split()))
c = 0
for i in s:
    if i % 2 == 1:
        c+=1
if c % 2 == 1:
    print("NO")
else:
    print("YES")

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
c = 0
for i in a:
    c += i % 2
print("YES" if c % 2 == 0 else "NO")

Solution (Python):
N=int(input())
A=list(map(int,input().split()))
cnt=0

for num in A:
  if num%2==1:
    cnt +=1
    
if cnt%2==1:
  print("NO")
else:
  print("YES")

Solution (Python):
n = int(input())
line = map(int,input().split())
odd = []
for i in line:
  if i % 2 == 1:
    odd.append(i)
if len(odd) % 2 == 0:
  print("YES")
else:
  print("NO")

Solution (Python):
n = int(input())
cnt = 0
a = list(map(int, input().split()))
for i in a:
     
    if i % 2 == 1:
        cnt += 1

if cnt % 2 == 0:
    print("YES")

else:
    print("NO")

Solution (Python):
n=int(input())
A=list(map(int,input().split()))
cnt=0
for a in A:
  if a%2==1:cnt+=1
if cnt%2==0:print("YES")
else:print("NO")

Solution (Python):

from collections import Counter
def inputlist(): return [int(j) for j in input().split()]

N = int(input())
A = inputlist()
co =0
for i in range(N):
    if A[i] % 2 == 1:
        co+=1
if co % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
def solve():
    N = int(input())
    A = list(map(int, input().split()))

    if len([1 for x in A if x % 2 != 0]) % 2 != 0:
        return 'NO'
    else:
        return 'YES'

print(solve())

Solution (Python):
N = int(input())
A = [int(i) for i in input().split()]

cou = 0
for i in range(N):
    if A[i] % 2 == 1:
        cou += 1
        
if cou % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
n = int(input())
a = [int(i) for i in input().split()]

s = sum(a)
if s%2==1:
    print("NO")
else:
    print("YES")

Solution (Python):
n = int(input())
A = list(map(int, input().split()))
num_odd = 0
for a in A:
  if a % 2 == 1:
    num_odd += 1
if num_odd % 2 == 0:
  print('YES')
else:
  print('NO')

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
if sum([1 for b in a if b%2 == 1]) % 2 == 1:
    print('NO')
else:
    print('YES')

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
cnt = 0
for i in range(n):
    if a[i]%2 == 1:
        cnt += 1
if cnt%2 == 1:
    print('NO')
else:
    print('YES')

Solution (Python):
def main():
    N = int(input())
    *A, = map(int, input().split())

    even = 0

    for a in A:
        if a % 2 == 0: even += 1

    odd = N - even

    if odd % 2 == 1:
        return False
    else:
        return True

print('YES' if main() else 'NO')

Solution (Python):
b=input()
a=sum(list(map(int, input().split())))
print("YES" if a%2==0 else "NO")

Solution (Python):
def ii():return int(input())
def iim():return map(int,input().split())
def iil():return list(map(int,input().split()))

n = ii()
l = iil()
count = 0
for i in l:
    if i%2 == 1:
        count += 1
if count%2 == 0:
    print('YES')
else:
    print('NO')

Solution (Python):
import sys

n = int(input())
a = list(map(int, input().split()))

cnt = 0
for i in range(len(a)):
    if a[i] % 2 != 0:
        cnt += 1

print("YES") if cnt % 2 == 0 else print("NO")

Solution (Python):
n = int(input())
arr = list(map(int, input().split()))
tmp = 0
for i in range(n):
  if arr[i] % 2 == 1:
    tmp += 1
if tmp % 2 == 0:
  print('YES')
else:
  print('NO')

Solution (Python):
N = int(input())
arr = sorted(list(map(int, input().split())))
ans = 0
for i in arr:
    if i % 2 == 1:
        ans += 1
if ans % 2 == 1:
    print('NO')
else:
    print('YES')

Solution (Python):
import math
import fractions
import bisect
import collections
import itertools
import heapq
import string
import sys
import copy
from decimal import *
from collections import deque
sys.setrecursionlimit(10**7)
MOD = 10**9+7
INF = float('inf') 
def gcd(a,b):return fractions.gcd(a,b) 
def lcm(a,b):return (a*b) // fractions.gcd(a,b) 
def iin(): return int(sys.stdin.readline()) 
def ifn(): return float(sys.stdin.readline()) 
def isn(): return sys.stdin.readline().split() 
def imn(): return map(int, sys.stdin.readline().split()) 
def imnn(): return map(lambda x:int(x)-1, sys.stdin.readline().split()) 
def fmn(): return map(float, sys.stdin.readline().split()) 
def iln(): return list(map(int, sys.stdin.readline().split())) 
def iln_s(): return sorted(iln()) 
def iln_r(): return sorted(iln(), reverse=True) 
def fln(): return list(map(float, sys.stdin.readline().split())) 
def join(l, s=''): return s.join(l) 
def perm(l, n): return itertools.permutations(l, n) 
def perm_count(n, r): return math.factorial(n) // math.factorial(n-r) 
def comb(l, n): return itertools.combinations(l, n) 
def comb_count(n, r): return math.factorial(n) // (math.factorial(n-r) * math.factorial(r)) 
def two_distance(a, b, c, d): return ((c-a)**2 + (d-b)**2)**.5 
def m_add(a,b): return (a+b) % MOD
def print_list(l): print(*l, sep='\n')

def sieves_of_e(n):
    is_prime = [True] * (n+1)
    is_prime[0] = False
    is_prime[1] = False
    for i in range(2, int(n**0.5)+1):
        if not is_prime[i]: continue
        for j in range(i * 2, n+1, i): is_prime[j] = False
    return is_prime

N = iin()
A = iln()

odd_count = 0
for a in A:
    if a % 2 == 1:
        odd_count += 1

print('YES' if odd_count % 2 == 0 else 'NO')

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

odd = 0
for a in A:
    if a % 2:
        odd += 1
if odd % 2:
    print('NO')
else:
    print('YES')

Solution (Python):
x=int(input())
y=list(map(int, input().split()))
if x==1:
	print('YES')
else:
	if sum(y)%2==1:
		print('NO')
	else:
		print('YES')

Solution (Python):
n = int(input())
A = list(map(int,input().split()))
odd = 0
for a in A:
    if a%2!=0:
        odd += 1
print('YES' if odd%2==0 else 'NO')

Solution (Python):
def main():
    n = int(input())
    a = list(map(int, input().split()))
    m = sum(x % 2 == 1 for x in a)
    print('YES' if m % 2 == 0 else 'NO')


if __name__ == '__main__':
    main()

Solution (Python):
n  = int(input())
l = [int(i) for i in input().split()]

odd = [i for i in l if i % 2]

if len(odd) % 2:
    print('NO')
else:
    print('YES')

Solution (Python):
n=int(input())
i = list(map(int, input().split()))
s=0
for j in range(n):
  if i[j]%2==1:
    s+=1
if s%2==0:
  print("YES")
else:
  print("NO")

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
if sum(a) % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

cnt = 0
for i in a:
    if i % 2 != 0:
        cnt += 1
if cnt % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

count_odd = 0
for i in range(n):
  if a[i] % 2 == 1:
    count_odd += 1
if count_odd % 2 == 0:
  print("YES")
else:
  print("NO")

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
cnt = 0
for Ai in A:
    cnt += Ai%2
if(cnt%2==0):
    print("YES")
else:
    print("NO")

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
cnt = 0
for i in range(n):
    if a[i] % 2 == 1:
        cnt += 1
if cnt % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
n = int(input())
li = [int(x)%2 for x in input().split()]
if li.count(1)%2==1:
    print("NO")
else:
    print("YES")

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
c = 0
for i in a:
    if i & 1:
        c += 1
if c & 1 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):

n = int(input())
A = list(map(int,input().split()))

cnt = 0
for a in A:
    if a%2 == 1:
        cnt +=1
if cnt%2 == 0:
    print('YES')
else:
    print('NO')

Solution (Python):

import sys

def INT(): return int(input())
def MAP(): return map(int,input().split())
def LI(): return list(map(int,input().split()))

def main():
    N = INT()
    A = LI()
    count = 0
    for i in range(N):
        if A[i]&1:
            count += 1
    if count&1:
        print('NO')
    else:
        print('YES')


if __name__ == '__main__':
    main()

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
if sum(A) % 2 == 0:print("YES")
else: print("NO")

Solution (Python):
def main():
    n = int(input())
    numbers = list(map(int, input().split()))
    count_odd = 0
    for num in numbers:
        if num % 2:
            count_odd += 1
    print("YES" if count_odd % 2 == 0 else "NO")


if __name__ == '__main__':
    main()

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
count = 0
for i in range(n):
    if a[i] % 2 == 1:
        count += 1
if count % 2 == 1:
    print("NO")
else:
    print("YES")

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
cnt = 0
for i in range(N):
    if A[i] % 2 == 1:
        cnt += 1

if cnt % 2 == 0:
    answer = "YES"
else:
    answer = "NO"
print(answer)

Solution (Python):
n = int(input())
a = [int(i) for i in input().split()]
 
ans = 'YES'
if sum(a)%2 != 0:
  ans = 'NO'
  
print(ans)

Solution (Python):
N=int(input())
A=list(map(int,input().split()))
cnt=0
for i in range(N):
    if(A[i]%2==1):
        cnt+=1
print("YES" if (cnt==0 or cnt%2==0) else "NO")

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
o=0
for x in a:
    if x%2!=0:o+=1
if o%2==1:print("NO")
else:print("YES")

Solution (Python):
N = int(input())
A_list = list(map(int,input().split()))
odd_cnt = 0
for i in A_list:
    if i % 2 == 1:
        odd_cnt += 1
if odd_cnt % 2 == 1:
    print("NO")
else:
    print("YES")

Solution (Python):
n = input()
a = list(map(int, input().split()))
even = 0
odd = 0
for i in a:
    if i % 2 == 0:
        even += 1
    else:
        odd += 1
if odd % 2 == 0:
    print('YES')
else:
    print('NO')

Solution (Python):
def main():
    n = int(input())
    a = list(map(int, input().split()))
    cnt = 0
    for v in a:
        if v % 2 == 1:
            cnt += 1
    if cnt % 2 == 1:
        print("NO")
    else:
        print("YES")

if __name__ == "__main__":
    main()

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
ki = [i for i in a if i%2!=0]
if len(ki)%2 != 0:
    print('NO')
else:
    print('YES')

Solution (Python):
N = int(input())
A = list(map(int, input().split(' ')))
odd_count = 0
for a in A:
    if (a % 2 == 1): odd_count += 1
if odd_count % 2 == 0:
    print('YES')
else:
    print('NO')

Solution (Python):
N = int(input())
A = list(map(int,input().split()))

cnt = 0
for i in range(N):
    if A[i]%2==1:
        cnt += 1

if cnt%2==0:
    print("YES")
else:
    print("NO")

Solution (Python):
N = int(input())
A = map(int,input().split())
n_odd = [odd for odd in A if odd%2==1]
if len(n_odd)%2==1:
  print("NO")
else:
  print("YES")

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
odd = len([i for i in a if i%2==1])
if odd%2 != 0:
    print('NO')
else:
    print('YES')

Solution (Python):
n = int(input())
A = list(map(int, input().split()))

t = 0
for i in range(n):
    if A[i] % 2 == 1:
        t += 1
if t%2 == 1:
    print("NO")
else:
    print("YES")

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

odd = 0  
even = 0  
for ai in A:
    if ai % 2 == 0:
        odd += 1
    else:
        even += 1

if even % 2 == 0:
    print('YES')
else:
    print('NO')

Solution (Python):
from functools import reduce
from operator import xor

n = int(input())
aaa = list(map(int, input().split()))
print('YES' if reduce(xor, aaa) & 1 == 0 else 'NO')

Solution (Python):
n = int(input())
a = map(int, input().split())

odd = 0
for i in a:
	if i % 2 == 1: odd += 1
print('YES' if odd % 2 == 0 else 'NO')

Solution (Python):
N=int(input())
A=list(map(int,input().split()))
oddcount=0
for i in range(N):
    if A[i]%2==1:
        oddcount=oddcount+1
if oddcount%2==1:
    print("NO")
else:
    print("YES")

Solution (Python):
n = int(input())
al = list(map(int, input().split(' ')))

if sum(al) % 2 == 0:
    print('YES')
else:
    print("NO")

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
cnt=0
for i in range(n):
    if a[i]%2==1:
        cnt+=1
if cnt%2==0:
    print("YES")
else:
    print("NO")

Solution (Python):
n = int(input())
al = list(map(int, input().split()))

if sum(al) % 2 ==0:
    print('YES')
else:
    print('NO')

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

odd_count = 0
even_count = 0

for i in A:
    if i%2==1:
        odd_count += 1
    else:
        even_count += 1

if odd_count%2==1:
    print("NO")
else:
    print("YES")

Solution (Python):
N, *A = map(int, open(0).read().split())
print("YNEOS"[sum(a&1 for a in A)&1::2])

Solution (Python):
N  = int(input())
A = [int(i) for i in input().split()]

odd = 0
for a in A:
    if a % 2 == 1:
        odd += 1

if odd % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
import sys
input = sys.stdin.readline

def main():
    N = int(input())
    a_list = list(map(int, input().split()))
    if sum(a_list) % 2 == 1:
        print("NO")
    else:
        print("YES")

if __name__ == '__main__':
    main()

Solution (Python):
import sys
input = sys.stdin.readline

def main():
    N = int(input())
    a_list = list(map(int, input().split()))
    odds = [a for a in a_list if a % 2 == 1]
    if len(odds) % 2 == 1:
        print("NO")
    else:
        print("YES")

if __name__ == '__main__':
    main()

Solution (Python):
N = int(input())
list_A = [int(x) for x in input().split()]

odd = 0
for A in list_A :
    if A%2 == 1 :
        odd += 1

if odd%2 == 0 :
    print("YES")
else :
    print("NO")

Solution (Python):
import numpy as np

n = int(input())
a = np.array(input().split(), np.int64)

if np.count_nonzero(a % 2 == 1) % 2 == 1:
    print('NO')
else:
    print('YES')

Solution (Python):
n = int(input())
a = [int(i) for i in input().split()]

c = 0

for i in a:
    if i % 2 != 0:
        c += 1

print("YES" if c % 2 == 0 else "NO")

Solution (Python):




N = int(input().strip())
A_list = list(map(int, input().rstrip().split()))


count=0
for i in A_list:
    if (i % 2) != 0:
        count += 1

if (count % 2) == 0:
    result = "YES"
else:
    result = "NO"

print(result)

Solution (Python):
import sys

read = sys.stdin.buffer.read
input = sys.stdin.buffer.readline
inputs = sys.stdin.buffer.readlines






def main():
	n=int(input())
	A=list(map(int,input().split()))
	
	ans="YES"
	
	if sum(A)%2:
		ans="NO"
	
	print(ans)
	
if __name__ == "__main__":
	main()

Solution (Python):
N=input()
a=list(map(int,input().split()))


odd=0
for i in a:
  if i%2==1:
    odd+=1
if(odd%2==0):
  print("YES")
else:
  print("NO")

Solution (Python):
n = input()
a = list(map(int, input().split()))

odd_cnt = len([1 for ai in a if ai % 2])
print('YES' if odd_cnt % 2 == 0 else 'NO')

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
count = 0
for i in range(N):
    if A[i] % 2 == 1:
        count += 1
if count % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
N = int(input())
A = [int(a) for a in input().split()]
odd = 0
for i, a in enumerate(A):
  odd += a % 2
print("YES" if odd % 2 == 0 else "NO")

Solution (Python):
import sys

def getN():
    return int(input())
def getNM():
    return map(int, input().split())
def getlist():
    return list(map(int, input().split()))
import math
import bisect
import heapq
from collections import defaultdict, Counter, deque
MOD = 10**9 + 7
INF = 10**15

def main():
    n = getN()
    nums = getlist()
    eo = [0, 0]
    for num in nums:
        eo[num % 2] += 1
    e = (eo[0] + eo[1] // 2) % 2
    o = eo[1] % 2
    if o == 0:
        print("YES")
    else:
        print("NO")
    

if __name__ == '__main__':
    main()

"""
9999
3

2916
"""

Solution (Python):











import sys
sys.setrecursionlimit(10**6)
input=sys.stdin.readline
from math import floor,sqrt,factorial,hypot,log 
from heapq import heappop, heappush, heappushpop
from collections import Counter,defaultdict,deque
from itertools import accumulate,permutations,combinations,product,combinations_with_replacement
from bisect import bisect_left,bisect_right
from copy import deepcopy
from fractions import gcd
from random import randint
def ceil(a,b): return (a+b-1)//b
inf=float('inf')
mod = 10**9+7
def pprint(*A): 
    for a in A:     print(*a,sep='\n')
def INT_(n): return int(n)-1
def MI(): return map(int,input().split())
def MF(): return map(float, input().split())
def MI_(): return map(INT_,input().split())
def LI(): return list(MI())
def LI_(): return [int(x) - 1 for x in input().split()]
def LF(): return list(MF())
def LIN(n:int): return [I() for _ in range(n)]
def LLIN(n: int): return [LI() for _ in range(n)]
def LLIN_(n: int): return [LI_() for _ in range(n)]
def LLI(): return [list(map(int, l.split() )) for l in input()]
def I(): return int(input())
def F(): return float(input())
def ST(): return input().replace('\n', '')
def main():
    N=I()
    A=LI()
    print(["YES","NO"][len([1 for i in A if i&1])%2])
if __name__ == '__main__':
    main()

Solution (Python):
n=int(input())
A=list(map(int,input().split()))
co=int(0)
for i in range(n):
    if A[i]%2==1:
        co+=1
if co%2==1:
    print("NO")
else:
    print("YES")

Solution (Python):
n=int(input())
a=[int(i) for i in input().split()]
ev=0
od=0
for i in a:
  if i%2==0:
    ev+=1
  else:
    od+=1
ans=False
if od%2==0:
  ans=True
else:
  if ev==0:
    ans=True
    
print('YES' if ans else 'NO')

Solution (Python):
N = int(input())
A = [int(a) for a in input().split()]
odd = 0
for i, a in enumerate(A):
  odd += a % 2
print("YES" if odd % 2 == 0 else "NO")

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

odd, even = 0, 0
for a in A:
    if a % 2 == 0:
        even += 1
    else:
        odd += 1

d, m = divmod(odd, 2)
even += d
odd = m

if odd == 0:
    ans = "YES"
else:
    ans = "YES" if even == 0 else "NO"

print(ans)

Solution (Python):
def main():
    N = int(input())
    A = [int(i) for i in input().split()]
    odd = len([a for a in A if a & 1])
    even = N - odd
    if odd & 1:
        print("NO")
    else:
        print("YES")


if __name__ == '__main__':
    main()

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
cnt = 0
for i in range(n):
    if a[i] % 2 == 1:
        cnt += 1
if cnt % 2 == 0:
    print('YES')
else:
    print('NO')

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
even = 0
odd = 0
for i in range(N):
    if A[i] % 2 == 0:
        even += 1
    else:
        odd += 1
if odd % 2 == 0:
    print('YES')
else:
    print('NO')

Solution (Python):
N=int(input())
L=list(map(int,input().split()))
count=0
for i in range (N):
	if L[i]%2==1:
		count+=1
if count%2==1:
	print("NO")
else:
	print("YES")

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
c = 0
for e in A:
    if e%2 == 1:
        c += 1
if c%2 == 1:
    print("NO")
else:
    print("YES")

Solution (Python):
if __name__ == "__main__":
    n = int(input())
    a = list(map(int, input().split()))

    count = 0

    for i in range(n):
        if a[i] % 2 == 1:
            count += 1

    if count % 2 == 1:
        print('NO')
    else:
        print('YES')

Solution (Python):
N  = int(input())
A = [int(i) for i in input().split()]

odd = 0
for a in A:
    if a % 2 == 1:
        odd += 1

if odd % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
n,*a=map(int,open(0).read().split());print("YNEOS"[sum(map(lambda x:x%2, a))%2::2])

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
cnt=0
for i in range(n):
    if a[i]%2!=0:
        cnt+=1
print('YES' if cnt%2==0 else 'NO')

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
odds = len([1 for a in A if a%2])
print('YES' if odds%2==0 else 'NO')

Solution (Python):
n = int(input())
l = list(map(int, input().split()))
t = 0
for i in range(n):
  if l[i]%2 == 1:
    t += 1
if t%2 == 1:
  print('NO')
else:
  print('YES')

Solution (Python):
n = int(input())
a = list(map(int,input().split()))

o,e = 0,0
for i in a:
    if i % 2 == 0:
        e += 1
    else:
        o += 1

if o % 2 == 1:
    print('NO')
    exit()

print('YES')

Solution (Python):
def main():
    N = int(input())
    A = list(map(int,input().split()))
    n_odd = len([A[i] for i in range(N) if A[i]%2 != 0])
    n_even = N - n_odd
    if n_odd%2 != 0:
        print("NO")
    else:
        print("YES")

if __name__ == '__main__':
    main()

Solution (Python):
n = int(input())
li_a = list(map(int, input().split()))
c_kisuu = len([a for a in li_a if a % 2 != 0])

if c_kisuu % 2 != 0:
    print("NO")
else:
    print("YES")

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
y = 0
for i in a:
    if i % 2 != 0:
        y += 1
if y % 2 == 0:
    print('YES')
else: print('NO')

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
a = len([i for i in A if i % 2 == 1])

if a % 2 == 0:
  print("YES")
else:
  print("NO")

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
A2 = [i%2 for i in A]
ac = A2.count(1)
if ac%2:
    print('NO')
else:
    print('YES')

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
count=0
for i in range(n):
  if l[i]%2==1:
    count+=1
if count%2==0:
  print('YES')
else:
  print('NO')

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

ar = []
for val in a:
    ar.append(val % 2)

if sum(ar) % 2:
    print('NO')
else:
    print('YES')

Solution (Python):
n = int(input())
nums = list(map(int, input().split()))

print('NO' if (sum(map(lambda x:x%2, nums)))%2 else 'YES')

Solution (Python):
N = int(input())
A_lst = [int(n) for n in input().split()]
odd = 0
even = 0
for A in A_lst:
    if A%2 == 0:
        even += 1
    else:
        odd += 1
print('YES') if odd%2 == 0 else print('NO')

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

even = 0
odd = 0
for a in A:
    if a % 2 == 0:
        even += 1
    else:
        odd += 1

odd_rest = odd % 2
even += odd // 2
even_rest = even % 2

if (odd_rest + even_rest) == 2:
    print("NO")
else:
    print("YES")

Solution (Python):
n = int(input())
a = [int(_) for _ in input().split()]

cnt = 0
for i in a:
    if i % 2 != 0:
        cnt += 1
if cnt % 2 == 0:
    print('YES')
else:
    print('NO')

Solution (Python):
import sys
n = int(input())
a_ls = [int(i) for i in sys.stdin.readline().split()]
if sum([i % 2 for i in a_ls]) % 2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
a_sum = sum([a[i]%2 for i in range(n)])
print("YES" if (a_sum % 2 == 0) else "NO")

Solution (Python):
import sys
sys.setrecursionlimit(10**6)
from math import floor,ceil,sqrt,factorial,log
from heapq import heappop, heappush, heappushpop
from collections import Counter,defaultdict,deque
from itertools import accumulate,permutations,combinations,product,combinations_with_replacement
from bisect import bisect_left,bisect_right
from copy import deepcopy
from operator import itemgetter
from fractions import gcd
mod = 10 ** 9 + 7
 

def ii(): return int(sys.stdin.readline().rstrip()) 
def mii(): return map(int,sys.stdin.readline().rstrip().split())
def limii(): return list(mii()) 
def lin(n:int): return [ii() for _ in range(n)]
def llint(n: int): return [limii() for _ in range(n)]

def ss(): return sys.stdin.readline().rstrip() 
def mss(): return sys.stdin.readline().rstrip()
def limss(): return list(mss()) 
def lst(n:int): return [ss() for _ in range(n)]
def llstr(n: int): return [limss() for _ in range(n)]





n=ii()
arr=limii()

cnt=0
for i in range(n):
    if arr[i]%2==1:
        cnt+=1

if cnt%2==1:
    print("NO")
else:
    print("YES")

Solution (Python):
input()
if len(["" for i in input().split() if int(i)%2 == 1])%2 == 0:
    print("YES")
else:
    print("NO")

Solution (Python):
N=int(input())
A=list(map(int,input().split()))

odd=0
for i in range(0,N):
    if A[i]%2==1:
        odd=odd+1

if odd%2==1:
    print('NO')
else:
    print('YES')

Solution (Python):
N = map(int, input().split())
A = [int(i) for i in input().split()]
oddCount = 0
for a in A:
    if a % 2:
        oddCount += 1
print("YES" if oddCount % 2 == 0 else "NO")