import sys

n = int(input())
a = [int(x) for x in input().split()]
d = set()
for i in a:
    if i in d:
        print("NO")
        exit()
    d.add(i)
print("YES") import sys sys n = int(input()) n int(input()) int input() input int(x) for x in input().split() for x in input().split() x input().split() ().split () input split for x in input().split() int(x) int x a = [int(x) for x in input().split()] a [int(x) for x in input().split()] d = set() d set() set for i in a:
    if i in d:
        print("NO")
        exit()
    d.add(i) i a if i in d:
        print("NO")
        exit()
     i in d i d print("NO") print "NO" exit() exit d.add(i) d.add d add i print("YES") print "YES" n = int(input()) int(input()) n d = set() set() d a = [int(x) for x in input().split()] [int(x) for x in input().split()] a
import sys

n = int(input())
a = [int(x) for x in input().split()]
d = set()
for i in a:
    if i in d:
        print("NO")
        exit()
    d.add(i)
print("YES")