peterverebics/CodeNet_Python_118 huggingface dataset:
s, t = input().split()
a, b = map(int, input().split())
u = input()

if s == "reb" and t == "blue":
    if u == "red":
        print(int(a-1),b)
    else:
        print(a,int(b-1))
else:
    if u == "blue":
        print(a,int(b-1))
    else:
        print(int(a-1),b)
def resolve():
    import sys
    input = sys.stdin.readline
    
    S, T = input().split()
    A, B = map(int, input().split())
    U = input()

    if U == S:
        print("{} {}".format(A-1, B))
    else:
        print("{} {}".format(A, B-1))


if __name__ == "__main__":
    resolve()
A=input().split()
B=list(map(int,input().split()))
B=list(map(lambda x:x-1,B))
print(B[0],B[1])
colors = list(map(str, input().split()))
numbers = list(map(int, input().split()))
target_color = input()

dictionary = {}
for index, color in enumerate(colors):
  dictionary[color] = numbers[index]
  if color == target_color:
    dictionary[color] = dictionary[color] - 1
  
 
for color in dictionary.keys():
  print(str(dictionary[color]) + " ", end="")
S,T = input().split()
A,B = map(int,input().split())
u = input()
print(S,T,u)
if S == u:
    print(A-1, B)
elif T == u:
    print(A, B-1)
S,T=map(str,input().split())
A,B=map(int,input().split())
U=str(input())
print(A-1 if S==U else B-1)
s,t =input().split()
a,b = map(int, input().split())
u = input()

print("2 4")

# if s == u:
#     a-=1
#     print(f'{a} {b}')
# else:
#     b-=1
#     print(f'{a} {b}')
s,t = input().split()
a,b = map(int, input().split())
u = input()

if s == u or t == u:
  print(a+b-1)
else:
  print(a+b)
s,t=input().split()
a,b=map(int,input().split())
u=input().split()

if s==u:
    print(a-1,b)
else:
    print(a,b-1)
s,t=input().split()
a,b=map(int,input().split())
u=input()
if s==u:
  print(a-1)
elif t==u:
  print(b-1)
S, T = map(str, input().split())
A, B = map(int, input().split())
U = input()

dict = {S: A, T: B}
if (dict[U] != 0):
    dict[U] = dict[U] - 1

values = []
for k, v in dict.items():
    values.append(v)

print(' '.join(map(str, values)))
t=list(input())
n=int((len(t)+1)//2)
p=0
for i in range(1,n):
    for j in range(1,i):
        if t[2*i]==t[2*j]:
            p+=1
if p>0:
    print("NO")
else:
    print("YES")
#n = int(input())
s,t = map(str,input().split())
a,b = map(int,input().split())
u = input()

#a_L = list(map(int,input().split()))

if u == "red":
    print(a-1,b)
else:
    print(a,b-1)
S, T = input().split()
A, B = map(int, input().split())
U = input()

print("S-1 T" if U == S else "S T-1")
s, t = list(map(str, input().split()))
a, b = list(map(int, input().split()))
u = input()

if s == u:
  print(a-1,b)
if s == t:
  print(b,a-1)
N_dict  = {i:0 for i in list(map(str,input().split()))}
N_List = list(map(int,input().split()))
ct = 0
for i in N_dict.keys():
    N_dict[i] = N_List[0]
    ct += 1

N_dict[str(input())] -= 1
" ".join(list(map(str,N_dict.values())))
s, t = input().split()
a, b = map(int, input().split())
u = input()

if s == u:
    print(a - 1, b)
else:
    print((a, b - 1))
S,T=input().split()
a,b=map(int,input().split())
U=input()
print(a-1,b) if S==U else (a,b-1)
S, T = map(str, input().split())
A, B = map(int, input().split())
U = input()

if U == "blue":
    print(str(A) + "" +str(int(B-1)))
else:
    print(str(int(A-1)) + "" +str(int(B)))
s,t = map(str,input().split())
a,b = map(int,input().split())
u = input()
if u=='red' and s=='red': print(a-1,b)
elif u=='red' and t=='red': print(a,b-1)
elif u=='blue' and s=='blue': print(a-1,b)
elif u=='blue' and t=='blue': print(a,b-1)
n = int(input())
a = list(map(int,input().split()))
s = set(a)
if len(a) == len(s):
  print('YES')
else:
  print('NO')
N=int(input())
A=list(map(int,input().split()))
if len(A)!=len(list(set(A))):
  print("NO")
else:
  print("YES")
import bisect,collections,copy,heapq,itertools,math,numpy,string
import sys
sys.setrecursionlimit(10**7)

def S(): return sys.stdin.readline().rstrip()
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())

def main():
    N = I()
    A = LI()
    print("YES" if len(list(set(A)))==len(A) else "NO")


main()
n = int(input())
a = input().split()
s = set()

dup = False
for i in a:
    if i in s:
        dup = True
    else:
        s.add(i)

if dup:
    print("NO")
else:
    print("YES")
from collections import Counter
n = int(input())
a = list(map(int,input().strip().split()))
if Counter(a).most_common(1)[0][1] != 1:
    print('NO')
else:
    print('YES')
n=int(input())
a=list(map(int,input().split()))
a.sort()
s="YES"
for i in range(n-1):
    if a[i]==a[i+1]:
        s="NO"
        break
print(s)
n = int(input())
A = list(map(int, input().split()))

print('YES' if len(A)==len(set(A)) else 'NO')
n = int(input())
a = list(map(int,input().split()))

if len(a) == len(set(a)):
    print("YES")
else:
    print("NO")
n = int(input())
a = list(map(int, input().split()))
print('YES' if len(a) == len(set(a)) else 'NO')
n = int(input())
l = list(map(int, input().split()))
l.sort()

same = False
for i in range(0, n-1):
    if l[i] == l[i+1]:
        same = True
        break

print('NO' if same else 'YES')
n=int(input())
a=list(map(int,input().split()))
a.sort()
ans='YES'
for i in range(1,len(a)):
    if a[i-1]==a[i]:
        ans="NO"
        break

print(ans)
import sys

readline = sys.stdin.readline
MOD = 10 ** 9 + 7
INF = float('INF')
sys.setrecursionlimit(10 ** 5)


def main():
    N = int(readline())
    A = list(map(int, readline().split()))
    S = set(A)

    if len(S) == N:
        print("YES")
    else:
        print("NO")


if __name__ == '__main__':
    main()
n = int(input())
s = list(map(int,input().split()))

s.sort()
flg = True
for i in range(n-1):
    if s[i] == s[i+1]:
        flg = False
        break

if flg:
    print("YES")
else:
    print("NO")
N=int(input())

A=[int(i) for i in input().split(" ")]
if len(set(A))==N:
    print("YES")
else:
    print("NO")
N = int(input())
li = list(map(int, input().split()))
li.sort()


S = 1
for i in range(N-1):
    if  li[i+1] == li[i]:
        S = S*0
    else:
        S = S
if S == 0:
    print('NO')
else:
    print('YES')
N = input()
A = list(map(int, input().split()))

set_A = set(A)
if len(A)==len(set_A):
    print('YES')
else:
    print('NO')
n = int(input())
a = list(map(int, input().split()))
if n == len(set(a)):
    print("YES")
else:
    print("NO")
#coding:utf-8
n=int(input())
A=list(map(int,input().split()))
if len(A)==len(set(A)):
  print('YES')
else:
  print('NO')
n=int(input())
a=[int(v) for v in input().split()]
check=1
a.sort()
for i in range (0,n-1):
    if a[i]==a[i+1]:
        check=0
        break
if check==0:
    print("NO")
else:
    print("YES")
from collections import defaultdict

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

D = defaultdict(int)

for i in range(N):
    D[A[i]] += 1
    if D[A[i]] == 2:
        print('NO')
        break
else:
    print('YES')
n = int(input())
a = input().split()
if (len(a) == len(set(a))):
  print("YES")
else:
  print("NO")
n = int(input())
a = list(map(int, input().split()))
print("YES" if len(list(set(a))) == n else "NO")
n = int(input())
a = list(map(int, input().split()))

if len(set(a)) == n:
    print('YES')
else:
    print('NO')
N=int(input())
A=list(map(int,input().split()))
from collections import defaultdict
d=defaultdict(int)
for a in A:
    d[a]+=1
print(['NO','YES'][all([1 if x==1 else 0 for x in d.values()])])
n = int(input())
an = list(map(int, input().split()))
 
def distinct_or_not(an):
    an_dict = {}
    for a in an:
        if a in an_dict:
            return False
        else:
            an_dict[a] = 1
    return True
  
if distinct_or_not(an):
    print('YES')
else:
    print('NO')
N = int(input())
A = list(map(int,input().split()))

A.sort()
ans = 'YES'
for i in range(N-1):
    if A[i] == A[i+1]:
        ans = 'NO'

print(ans)
N = int(input())
A = list(map(int, input().split()))
if len(set(A)) == N:
    print('YES')
else:
    print('NO')
n=int(input())
a=list(map(int,input().split()))
a.sort()
for i in range(n-1):
    if a[i] == a[i+1]:
        print('NO')
        exit()
print('YES')
N=int(input())
A=list(map(int,input().split()))
A1=set(A)
ans="NO"
if len(A)==len(A1):
    ans="YES"
print(ans)
n = int(input())
print("YES" if len(set(input().split())) == n else "NO")
N = int(input())
Ai = list(map(int, input().split()))
Ai_set = set(Ai)
if len(Ai) - len(Ai_set) == 0:
    print('YES')

else:
    print('NO')
n = int(input())
nums = set(input().split())

if n == len(nums):
  print("YES")
else:
  print("NO")
length = int(input())
numList = input().split()
checkSet = set()
for num in numList:
  checkSet.add(num)
if(len(checkSet) == len(numList)):
  print("YES")
else:
  print("NO")
n = int(input())
s = [int(i) for i in input().split()]
s.sort()
flag = False
for i in range (0,n-1):
  if s[i] == s[i+1]:
    flag = True
    break
if flag == True:
  print("NO")
else: print("YES")
# -*- coding: utf-8 -*-
n = int(input())
a = [int(i) for i in input().split()] 

if len(set(a)) == n:
    print("YES")
else:
    print("NO")
N=int(input())
A=list(map(int,input().split()))
B=set(A)
if N==len(B):
  print('YES')
else:
  print('NO')
# -*- coding: utf-8 -*-
"""
Created on Sun Feb  9 20:52:55 2020

@author: H_Hoshigi
"""

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

A_list.sort()
A_now = 0
answer = "YES"
for i in A_list:
    if i == A_now:
        answer = "NO"
        break
    else:
        A_now = i

print(answer)
from collections import Counter

n = int(input())
c = Counter(map(int, input().split()))

print("YES" if c.most_common(1)[0][1] <= 1 else "NO")
n = int(input())
a = input().split()
b = set(a)
if len(b)<len(a):
    print("NO")
else:
    print("YES")
n = int(input())
As = list(map(int, input().split()))
if len(As) == len(set(As)):
    print('YES')
else:
    print('NO')
N = int(input())
A = list(map(int, input().split()))

A_set = set(A)

if len(A) == len(A_set):
  print('YES')
else:
  print('NO')
def has_duplicates(seq):
    return len(seq) != len(set(seq))
N = input().rstrip().split(' ')[0]
print('NO') if has_duplicates([int(i) for i in input().rstrip().split(' ')]) else print('YES')
# -*- coding: utf-8 -*-
n = int(input())
my_list = list(map(int, input().split()))

my_set = set()

for item in my_list:
    if item in my_set:
        print('NO')
        exit()
    else:
        my_set.add(item)

print('YES')
N=int(input())
A=set(map(int,input().split()))
print('YNEOS'[N!=len(A)::2])
N = int(input())
A = list(map(int, input().split()))

set_A = set(A)

if len(A) == len(set_A):
  print('YES')
else:
  print('NO')
N = int(input())
an = list(map(int, input().split()))

set_an = set(an)

print("YES" if len(set_an) == N else "NO")
from collections import Counter


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

if max(cnt.values()) == 1:
    print('YES')
else:
    print('NO')
N = int( input() )
A = [int(x) for x in input().split()]

if( N == len( list(set(A)) ) ):
    print( 'YES' )
else:
    print( 'NO' )
N = int(input())
A = list(map(int, input().split()))
S = list(set(A))

if len(A) == len(S):
  print("YES")
else:
  print("NO")
n = int(input())
a = list(map(int,input().split()))

if len(a) != len(set(a)):
  print("NO")
else:
  print("YES")
N = int(input())
A = list(map(int, input().split()))
if N == len(list(set(A))):
  print('YES')
else:
  print('NO')
'''
INPUT SHORTCUTS
N, K = map(int,input().split())
N ,A,B = map(int,input().split())
string = str(input())
arr = list(map(int,input().split()))
N = int(input())
'''

N = int(input())
arr = list(map(int,input().split()))
arr.sort()
ans = 0
for i in range(N-1):
	if arr[i]==arr[i+1]:
		ans = 1
		break

if ans:
	print("NO")
else:
	print("YES")
n = int(input())

a = list(map(int, input().split()))
b = set(a)

print('YES' if len(a) == len(b) else 'NO')
N=int(input())
A=list(map(int,input().split()))
import collections

c = collections.Counter(A)
c = c.most_common()
if c[0][1] == 1:
  print("YES")
else:
  print("NO")
n=int(input())
a=list(map(int,input().split()))
b=list(set(a))
if len(a)==len(b):
  print("YES")
else:
  print("NO")
n = int(input())
a = set(map(int, input().split()))
print('YES' if n == len(a) else 'NO')
import collections
n = int(input())
a = list(map(int,input().split()))

li = collections.Counter(a)

li2 = [i for i in li.values()]

if max(li2)==1:
    print("YES")
else:
    print("NO")
def solve(n, a_list):
    if len(set(a_list)) == n:
        return "YES"
    else:
        return "NO"


def main():
    n = int(input())
    a_list = list(map(int, input().split()))
    res = solve(n, a_list)
    print(res)


def test():
    assert solve(5, [2, 6, 1, 4, 5]) == "YES"
    assert solve(6, [4, 1, 3, 1, 6, 2]) == "NO"
    assert solve(2, [10000000, 10000000]) == "NO"


if __name__ == "__main__":
    test()
    main()
N = int(input())
A = map(int,input().split())
B = set(A)

if N == len(B):
    print("YES")
else:
    print("NO")
n=int(input())
a=[i for i in map(int, input().split())]

a.sort()
for i in range(n-1):
    if a[i]==a[i+1]:
        print('NO')
        exit(0)
print('YES')
N = int(input())
A = list(map(int, input().split()))
A.sort()

ans = "YES"
for i in range(N-1):
    if A[i] == A[i+1]:
        ans = "NO"

print(ans)
# coding: utf-8
# Your code here!
N = int(input())
A = list(map(int,input().split()))
n = len(list(A))
m = len(set(A))
if n == m:
    print("YES")
else:
    print("NO")
n=int(input())
a=[int(i) for i in input().split()]
cnt={}
for i in range(n):
    cnt[a[i]]=0
ok=1
for i in range(n):
    cnt[a[i]]+=1
    if cnt[a[i]]==2:
        print("NO")
        ok=0
        break
if ok==1:
    print("YES")
# coding: utf-8
# 標準入力 <int>
N = int(input())
# 標準入力 <int> list[]
A = list(map(int, input().split()))

if (len(set(A)) == N):
    print("YES")
else:
    print("NO")
N = int(input())
print('YES' if len(set(input().split())) == N else 'NO')
n = int(input())
alist = list(map(int,input().split()))
aset = set(alist)
if len(alist) == len(aset):
  print("YES")
else:print("NO")
N = int(input())
A = list(map(int, input().split()))

S = set(A)

if len(A) == len(S):
    print ('YES')
else:
    print ('NO')
n=int(input())
a=list(map(int,input().split()))
if len(a)==len(list(set(a))):
  print("YES")
else:
  print("NO")
import copy
import math
import string
import heapq
import bisect
import sys
sys.setrecursionlimit(10**7)

N = int(input())
A = set(map(int,input().split()))
if N == len(A):
    print("YES")
else:
    print("NO")
i=input;print(['NO','YES'][int(i())==len(set(i().split()))])
import sys
import numpy as np

n = input()

a = input().split()

a_n = np.array(a)

if (len(a) == np.unique(a_n).size):
    print("YES")
else:
    print("NO")
#整数値入力 1文字の入力
def input_one_number():
    return int(input())

#整数値龍力　複数の入力(配列)
def input_multiple_number_as_list():
    return list(map(int, input().split()))


n = input_one_number()
asnyan = input_multiple_number_as_list()

asnyan.sort()

b = 0
flg = True
for a in asnyan:
    if b == a:
        flg = False
    b = a

if flg:
    print("YES")
else:
    print("NO")
N = int(input())
A = list(map(int,input().split()))
B = sorted(A)
for i in range(N-1):
  if B[i] == B[i+1]:
    print('NO')
    exit()
print('YES')
n = int(input())
a = list(map(int, input().split()))
a.sort()
for i in range(n-1):
  if a[i] == a[i+1]:
    print('NO')
    exit(0)
print('YES')
from collections import Counter
n = int(input())
a = list(map(int,input().split()))
c = Counter(a)

if c.most_common()[0][1] == 1:
    print("YES")
else:
    print("NO")
N = int(input())
A_ls = input().split(' ')
A_set = { i for i in A_ls }
if len(A_set) == N:
    print('YES')
else:
    print('NO')
n = int(input())

lst = list(map(int, input().split()))

lset = set(lst)

if len(lset) == len(lst):
    print("YES")
else:
    print("NO")
N = int(input())
A = list(map(int,input().split()))
d = dict()
for i in range(N):
    d[A[i]]=0
for n in range(N):
    
    if d[A[n]] == 1:
        print("NO")
        break
    if n == N-1:
        print("YES")
    d[A[n]] = 1
#  --*-coding:utf-8-*--

N = input()
A = sorted(map(int, input().split()))

lastA = None
for a in A:
    if a == lastA:
        print('NO')
        break
    
    lastA = a
else:
    print('YES')
N = int(input())
A = list(map(int,input().split()))

if len(set(A)) == len(A):
  print("YES")
else:
  print("NO")
import numpy as np

N = int(input())
A = tuple(map(int, input().split()))
A = np.array(A)
A = np.sort(A)

for i in range(N):
    if (i > 0 and A[i-1] == A[i]) or (i < N-1 and A[i] == A[i+1]):
        print('NO')
        break
else:
    print('YES')
"""
int(input())
map(int,input().split())
list(map(int,input().split()))

"""

n=int(input())
s=list(map(int,input().split()))
if(len(s)==len(list(set(s)))):
    print("YES")
else:
    print("NO")
n=int(input())
A=set(map(int,input().split()))
if len(A)==n:
    print("YES")
else:
    print("NO")
import numpy as np

if __name__ == "__main__":
  _n = int(input())
  _l = [int(i) for i in input().split()]

  check = set()
  for i in _l:
    if i in check:
      print("NO")
      exit(0)
    else:
      check.add(i)
  print("YES")
N=int(input())
L=list(map(int,input().split()))
L=sorted(L)
X=-1
T=True
for i in L:
  if i!=X:
    X=i
  else:
    T=False
if T==True:
  print("YES")
else:
  print("NO")
n=int(input())
a=[int(i) for i in input().split()]
a.sort()
ch=0
for i in range(1,n):
    if a[i]==a[i-1]:
        ch=1
if ch==1:
    print("NO")
else:
    print("YES")
n = int(input())
a = sorted(list(map(int, input().split())))

for i in range(n - 1):
    if a[i] == a[i + 1]:
        print('NO')
        exit()
print('YES')
n,*a=map(int,open(0).read().split())
if len(a)==len(set(a)):
  print("YES")
else:
  print("NO")
N = int(input())
A = [int(x) for x in input().split()]
B = list(set(A))
if(len(A)==len(B)):
  print('YES')
else:
  print('NO')
import sys

N = int(input())
A = list(map(int,input().split()))
A.sort()

for i in range (0,N-1):
  if A[i] == A[i+1]:
    print("NO")
    sys.exit()
print("YES")
n=(int)(input())
a=sorted(list(map(int, input().split(" "))))
for i in range(n-1):
  if a[i] == a[i + 1]:
    print("NO")
    break
else:
  print("YES")
t = int(input())
a = list(map(int,input().strip().split()))
b = set(a)
if len(a) ==len(b):
    print('YES')
else:
    print('NO')
n = int(input())
a = list(map(int, input().split()))

ac = set(a)

if len(ac) == len(a):
    print("YES")
else:
    print("NO")
N = input()
A = input().split()

_A = set(A)

if len(A) == len(_A):
    print('YES')
else:
    print('NO')
N = input()
A = input().rstrip().split()
As = len(set(A))
if len(A) == As:
    print("YES")
else:
    print("NO")
n = int(input())
a = list(map(str, input().split()))
if(len(set(a)) != n):
    print("NO")
else:
    print("YES")
n=int(input())
a=list(map(int,input().split()))
b=set(a)
if len(a)==len(b):
    print("YES")
else:
    print("NO")
N = int(input())
P = list(map(int,input().split()))
def has_duplicates(seq):
    return str(len(seq) != len(set(seq)))
if has_duplicates(P) == 'False':
  print('YES')
elif has_duplicates(P) == 'True':
  print('NO')
import sys

input = sys.stdin.readline

N = int(input())
A = list(map(int, input().split()))
check = set(A)

if len(check) == N:
    print('YES')
else:
    print('NO')
N = int(input())
A = list(map(int, input().split()))

len_A = len(A)
A = set(A)
if len_A != len(list(A)):
    print("NO")
else:
    print("YES")
N = int(input())
A = input()
A_list = [int(x) for x in A.split()]

if len(A_list) == len(set(A_list)):
    print("YES")
else:
    print("NO")
n,*a=map(int,open(0).read().split());print("YNEOS"[len(a)!=len(set(a))::2])
import bisect, collections, copy, heapq, itertools, math, string
import sys
def I(): return int(sys.stdin.readline().rstrip())
def MI(): return map(int, sys.stdin.readline().rstrip().split())
def LI(): return list(map(int, sys.stdin.readline().rstrip().split()))
def S(): return sys.stdin.readline().rstrip()
def LS(): return list(sys.stdin.readline().rstrip().split())

from  collections import defaultdict
from collections import Counter
import bisect
def main():
     N = I()
     A = LI()
     c = Counter(A)
     if len(c.values()) == N:
         print('YES')
     else:
         print('NO')
if __name__ == "__main__":
    main()
n = int(input())
a = set(input().split())
print('YES' if len(a) == n else 'NO')
n = int(input())
a = list(map(int, input().split()))
p = set()
for i in a:
    if i in p:
        print('NO')
        exit()
    p.add(i)
print('YES')
def has_duplicates(seq):
    return len(seq) != len(set(seq))


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

flg = has_duplicates(a)

if not flg:
    print('YES')
else:
    print('NO')
N=int(input())
a=list(map(int,input().split()))
b=list(set(a))
if len(a)==len(b):
  print('YES')
else:
  print('NO')
n = int(input())
a = list(map(int,input().split()))

if n == len(set(a)):
  print('YES')
else:
  print('NO')
import collections
N = int(input())
A = list(map(int,input().split()))

K = collections.Counter(A)
B = len(K)

if N == len(K):
    print("YES")
else:
    print("NO")
def actual(n, A):
    if len(set(A)) == len(A):
        return 'YES'

    return 'NO'


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

print(actual(n, A))
n = int(input())

an = map(int, input().split())

if len(set(an)) == n :
    print("YES")
else :
    print("NO")
N=int(input())
a=list(map(int,input().split()))

a.sort()
flg=0
if(a[0]==a[1]):
    flg=1
for i in range(1,N-1):
    if(a[i]==a[i-1]):
        flg=1
if flg==1:
    print("NO")
else:
    print("YES")
n=int(input())
l1=list(map(int,input().split()))

if(len(l1)==len(set(l1))):
    print("YES")
else:
    print("NO")
n,*l=map(int,open(0).read().split())
print("YES" if len(set(l))==n else "NO")
N = map(int, input())
A = list(map(int ,input().split(' ')))
print('YES') if len(set(A))==len(A) else print('NO')
n=int(input())
a=list(map(int,input().split()))
a=len(list(set(a)))
if n==a:
  print('YES')
else:
  print('NO')
n= int(input())
che={}
ans='YES'
a = list(map(int, input().split()))
for i in a:
  if i in che.keys():
    ans='NO'
  else:
    che[i]=0
print(ans)
from collections import defaultdict
n = int(input())
d = defaultdict(int)
A = list(map(int,input().split()))

for a in A:
    if d[a] == 1:
        print('NO')
        exit()
    else:
        d[a] += 1

print('YES')
N=int(input())
Ai = list(map(int,input().split()))

Ai.sort()

flag = 0
for i in range(N-1):
  if(Ai[i] == Ai[i+1]):
    flag=1
    break
if (flag):
  print('NO')
else:
  print('YES')
n = int(input())
a = list(map(int, input().split()))
if len(a) == len(set(a)):
    print('YES')
else:
    print('NO')
N = input().strip()
Arr = input().strip().split(' ')
if len(Arr) - len(set(Arr)) == 0:
  print('YES')
else:
  print('NO')
n = int(input())
a = list(map(int,input().split()))

a.sort()

for i in range(n-1):  
  if a[i] == a[i+1]:
    print("NO")
    exit()

print("YES")
n = int(input())
s = set(input().split())
print('YES' if n == len(s) else 'NO')
#!/usr/bin/evn python3

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

A_set = len(set(A))
if N == A_set:
    print("YES")
else:
    print("NO")
n=int(input())
a=list(map(int,input().split()))
d={}
ans="YES"
for i in range(n):
  if(a[i] in d):
    ans="NO"
    break
  else:
    d[a[i]]=1
print(ans)
N = int(input())
A = list(map(int, input().split()))
setA = set(A)
if len(setA) == N:
    print('YES')
else:
    print('NO')
n=int(input())

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

s=list(set(a))
if len(a)==len(s):
    print('YES')
else:
    print('NO')
n = int(input())
a = list(map(int,input().split()))
if len(set(a)) == n:
    print('YES')
else:
    print('NO')
N = int(input())
A = list(map(int, input().split()))  # [1, 2, 3, 4] になる

len2 = len(set(A))
if N == len2:
    print('YES')
else:
    print('NO')
N = int(input())
A_ls = input().split(' ')
rst = set()
for i in A_ls:
    rst.add(i)
if len(rst) == N:
    print('YES')
else:
    print('NO')
N = int(input())
A = list(map(int,input().split()))
A = sorted(A)
flag = 0
for i in range(N-1):
    if A[i]==A[i+1]:
        flag = 1
        break
if flag == 0:
    print('YES')
else:
    print("NO")
n = int(input())
a = list(map(int, input().split()))
if len(a) != len(set(a)):
  print("NO")
else:
  print("YES")
n = int(input())
a = list(map(int, input().split()))

print('YES' if len(a) == len(set(a)) else 'NO')
N = int(input())
nums = input().split()
nums = set(nums)
if len(nums) == N:
  print("YES")
else:
  print("NO")