n = eval(input())

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

if len(set(a)) == len(a):

  print("YES")

elif len(set(a)) != len(a):

  print("NO")
n = eval(input())

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

if len(a)== len(set(a)):

  print("YES")

else:

  print("NO")
n = eval(input())
a = list(map(int, input().split()))
if len(set(a)) == len(a):
    print("YES")
elif len(set(a)) != len(a):
    print("NO")

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

-if len(set(a)) == len(a): +if len(a) == len(set(a)): -elif len(set(a)) != len(a): +else: