import collections 
n = int(input())
a = map(int,input().split())
c = collections.Counter(a)
c = c.values()
for i in c:
  if i!=1:
    print("NO")
    exit()
print("YES") import collections collections n = int(input()) n int(input()) int input() input a = map(int,input().split()) a map(int,input().split()) map int input().split() ().split () input split c = collections.Counter(a) c collections.Counter(a) collections.Counter collections Counter a c = c.values() c c.values() c.values c values for i in c:
  if i!=1:
    print("NO")
    exit() i c if i!=1:
    print("NO")
    exit() i!=1 i 1 print("NO") print "NO" exit() exit print("YES") print "YES" c = collections.Counter(a) collections.Counter(a) c a = map(int,input().split()) map(int,input().split()) a n = int(input()) int(input()) n c = c.values() c.values() c
import collections 
n = int(input())
a = map(int,input().split())
c = collections.Counter(a)
c = c.values()
for i in c:
  if i!=1:
    print("NO")
    exit()
print("YES")