CodeEff/ECCO huggingface dataset:
# Original solution
n=int(eval(input()))
a=list(map(int,input().split()))

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

# Optimized solution
n=int(eval(input()))
a=list(map(int,input().split()))

b=list(set(a))
if len(a)==len(b):
    print("YES")
else:
    print("NO")
# Original solution
num = eval(input())
inp = input().split()
res = []
final = ""
tem = 0
for i in inp:
   tem = inp.count(i)
   res.append(tem)
   tem = 0
for i in res:
   if i >= 2:
      final = "NO"
      break
   else:
      final = "YES"
print(final)


# Optimized solution
num = eval(input())
inp = input().split()
len1 = len(inp)
out = set(inp)
len2 = len(out)
if len1 == len2:
   print("YES")
else:
   print("NO")
# Original solution
N = int(eval(input()))
A = list(map(int, input().split()))
L = []
for i in range(N):
  if A[i] in L:
    print('NO')
    break
  L.append(A[i])
else:
  print('YES')

# Optimized solution
N = int(eval(input()))
A = list(map(int, input().split()))
A.sort()
for i in range(N-1):
  if A[i] == A[i+1]:
    print("NO")
    break
else:
  print('YES')
# Original solution
n = int(eval(input()))
num_list = list(map(int, input().split()))
out = "YES"
for j in range(len(num_list)):
    for k in num_list[j + 1:]:
        out = "NO" if num_list[j] == k else out
print(out)


# Optimized solution
n = int(eval(input()))
num_list = list(map(int, input().split()))
out = "YES" if len(num_list) == len(set(num_list)) else "NO"
print(out)
# Original solution
N = int(eval(input()))
A = list(map(int, input().split()))

i = 0
flag = 0
while(i<N-1):
  for j in range(1,len(A)):
    if(A[0]==A[j]):
      flag = 1
      break
  if(flag == 1):
    break
  else:
    A.pop(0)
  i += 1
if(flag == 1):
  print("NO")
else:
  print("YES")

# Optimized solution
N = int(eval(input()))
A = list(map(int, input().split()))

A.sort()
flag = 0
for i in range(N-1):
  if(A[i]==A[i+1]):
    flag = 1
    break
if(flag == 1):
  print("NO")
else:
  print("YES")
# Original solution
import math

def main():
    n = int(eval(input()))
    a = list(map(int, input().split()))
    cnt = {}
    for val in a:
        cnt[val] = cnt.get(val, 0) + 1
    distinct = True
    for val in cnt:
        if cnt[val] > 1:
            distinct = False
    if distinct:
        print("YES")
    else:
        print("NO")

if __name__ == '__main__':
    main()

# Optimized solution
n=int(eval(input()))
a=list(input().split())

if len(list(a))==len(set(a)):
    print('YES')
else:
    print('NO')
# Original solution
n = int(eval(input()))
a = list(map(int,input().split()))
flag = False
for i in range(n-1):
    for j in range (i+1,n):
        if a[i] == a[j]:
            flag = True
            break
print(('YES' if flag == False else 'NO'))

# Optimized solution
n=int(eval(input()))
a=[int(v) for v in input().split()]
a.sort()
kt=1
for i in range(0,n-1):
    if a[i]==a[i+1]:
        kt=0
        break
if kt==0:
    print("NO")
else:
    print("YES")
# Original solution
N = int(eval(input()))
A_List = list(map(int,input().split()))

for i in range(N):
    for j in range(i+1,N):
        if A_List[i]==A_List[j]:
            print("NO")
            exit()

print("YES")

# Optimized solution
N = int(eval(input()))
A_List = list(map(int,input().split()))

print(("YES" if len(A_List)==len(set(A_List)) else "NO"))
# Original solution
n=int(eval(input()))
a=list(map(int,input().split()))
print(('YES' if len(list(set(a)))==n else 'NO'))

# Optimized solution
n=int(eval(input()))
a=list(map(int,input().split()))
print(('YES' if len(set(a))==n else 'NO'))
# Original solution
N = int(eval(input()))
List = [int(i) for i in input().split(" ")]
flag = 0
for j in range(N-1):
    for k in range(j+1,N):
        if List[j]==List[k]:
            flag = 1
            break
        if flag==1:
            break
if flag==1:
    print("NO")
else:
    print("YES")

# Optimized solution
N = int(eval(input()))
List = [i for i in input().split(" ")]
Dict = {}
flag=0
for i in range(N):
    try:
        Dict[List[i]] += 1
    except KeyError:
        Dict[List[i]] = 1
        
list2 = list(Dict.values())
for j in range(len(list2)):
    if list2[j]>1:
        flag=1
if flag==1:
    print("NO")
else:
    print("YES")
# Original solution

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

for i in range(n):
    if a.count(a[i]) != 1:
        status = 1
        break
    else:
        pass

if status == 0:
    print("YES")
else:
    print("NO")


# Optimized solution

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

b = set(a)

if len(a) == len(b):
    print("YES")
else:
    print("NO")
# Original solution
n = int(eval(input()))
List = list(map(int, input().split()))
ans = 'YES'
for i in range(n - 1):
    for j in range(n - i - 1):
        if List[i] == List[i + j + 1]:
            ans = 'NO'
            break
    if ans == 'NO':
        break

print(ans)

# Optimized solution
n = int(eval(input()))
List = list(map(int, input().split()))
Sorted = sorted(List)
ans = 'YES'
for i in range(n - 1):
    if Sorted[i] == Sorted[i + 1]:
        ans = 'NO'
        break

print(ans)
# Original solution
a=int(eval(input()))
b=list(map(int, input().split()))
for i in b:
    if b.count(i)==1:
        continue
    elif b.count(i)>1:
        print('NO')
        break
else:
    print('YES')


# Optimized solution
a=int(eval(input()))
b=list(map(int, input().split()))

if len(b) != len(set(b)):
    print('NO')
else:
    print('YES')
# Original solution
n = int(eval(input()))
l = list(map(int, input().split()))
check = True
for i in range(n):
    if l.count(l[i]) > 1:
        check = False
        break
if check:
    print("YES")
else:
    print("NO")

# Optimized solution
n = int(eval(input()))
l = list(map(int, input().split()))
m = list(set(l))
if len(l) == len(m):
    print("YES")
else:
    print("NO")
# Original solution
N = int(eval(input()))
A = list(map(int,input().split()))

flg = 'YES'
for i,a in enumerate(A):
    if a in A[i+1:]:
        flg = 'NO'
        break

print(flg)

# Optimized solution
N = int(eval(input()))
A = list(map(int,input().split()))

X = set(A)
if len(A) == len(X):
    print('YES')
else:
    print('NO')
# Original solution
def main():
    N = int(eval(input()))
    A = list(map(int,input().split()))

    count = 0
    flag = False

    '''
    for i in A:
        if(A.count(i) > 1):
            flag = True
            break

    if(flag):
        print('NO')
    else:
        print('YES')
    '''

    for i in A:
        for j in A:
            if(i == j):
                count += 1
            if(count > 1):
                flag = True
                break
        count = 0

        if(flag):
            break

    if(flag):
        print('NO')
    else:
        print('YES')

if __name__ == "__main__":
    main()

# Optimized solution
def main():
    N = int(eval(input()))
    A = list(map(int,input().split()))

    count = 0
    flag = False

    set_A = set(A)

    if(len(set_A) == len(A)):
        print('YES')
    else:
        print('NO')
        
    '''
    for i in A:
        if(A.count(i) > 1):
            flag = True
            break

    if(flag):
        print('NO')
    else:
        print('YES')
    '''

'''
    for i in A:
        for j in A:
            if(i == j):
                count += 1
            if(count > 1):
                flag = True
                break
        count = 0

        if(flag):
            break

    if(flag):
        print('NO')
    else:
        print('YES')
        '''

if __name__ == "__main__":
    main()
# Original solution
print((['YES','NO'][int(eval(input()))>len(set(map(int,input().split())))]))

# Optimized solution
print(('YNEOS'[int(eval(input()))>len(set(input().split()))::2]))
# Original solution
n = int(eval(input()))
a = list(map(int, input().split()))

ans = 'YES'
for i in range(n):
    for j in range(i+1,n):
        if a[i] == a[j]:
            ans = 'NO'



print(ans)

# Optimized solution
n = int(eval(input()))
a = list(map(int, input().split()))

b = set(a)

if len(a) == len(b):
    print('YES')
else:
    print('NO')
# Original solution
N=int(eval(input()))
A=list(map(int,input().split()))
s=0
for i in range(N-1):
  for j in range(i+1,N):
    if A[i]!=A[j]:
      s=s
    else:
      s+=1
if s!=0:
  print("NO")
else:
  print("YES")

# Optimized solution
N=int(eval(input()))
A=list(map(int,input().split()))
n=len(set(A))
if N!=n:
  print("NO")
else:
  print("YES")
# Original solution
n = int(eval(input()))
import sys
an = list(map(int, sys.stdin.readline().split()))

for i in range(n):
    for j in range(i+1, n):
        if an[i] == an[j]:
            print('NO')
            exit(0)
print('YES')

# Optimized solution
n = int(eval(input()))
import sys
an = list(map(int, sys.stdin.readline().split()))

if len(set(an))==n:
    print('YES')
    exit(0)

print('NO')
# Original solution
N = int(eval(input()))
A = list(map(int, input().split()))
check = []

for a in A:
    if not a in check:
        check.append(a)
    else:
        print('NO')
        break
else:
    print('YES')

# Optimized solution
N = int(eval(input()))
A = list(map(int, input().split()))

if len(set(A)) == len(A):
    print('YES')
else:
    print('NO')
# Original solution
import sys
input = sys.stdin.readline
N = int(eval(input()))
a = list(map(int, input().split()))
s = set()
for x in a:
  if x in s:
    print("NO")
    exit(0)
  s.add(x)
print("YES")

# Optimized solution
import sys
input = sys.stdin.readline
N = int(eval(input()))
a = set(map(int, input().split()))
if N == len(a): print("YES")
else: print("NO")
# Original solution
n =int(eval(input()))
# print(n)
List=list(map(int,input().split()))
count = 0
# print(List)
# print(List[1])
for i in range(n):
    # print(List[i])
    count += List.count(List[i])
    # print(count)
if count == n:
    print('YES')
else:
    print('NO')

# Optimized solution
def has_duplicates(seq):
    return len(seq) != len(set(seq))

n =int(eval(input()))
List=list(map(int,input().split()))
if has_duplicates(List) == False:
    print('YES')
else:
    print("NO")
# Original solution
n = int(eval(input()))
a = list(map(int, input().split()))

frag = False

for i in range(n):
  for j in range(n):
    if i != j and a[i] == a[j]:
      frag = True
if frag:
  print("NO")
else:
  print("YES")

# Optimized solution
n = int(eval(input()))
a = list(map(int, input().split()))

b = set(a)

if len(a) == len(b):
  print("YES")
else:
  print("NO")
# Original solution
import sys, re, os
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
# from fractions import gcd
from itertools import permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from functools import reduce
from bisect import bisect_left, insort_left
from heapq import heapify, heappush, heappop

INPUT = lambda: sys.stdin.readline().rstrip()
INT = lambda: int(INPUT())
MAP = lambda: list(map(int, INPUT().split()))
S_MAP = lambda: list(map(str, INPUT().split()))
LIST = lambda: list(map(int, INPUT().split()))
S_LIST = lambda: list(map(str, INPUT().split()))

sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7


def main():
    N = INT()
    A = LIST()

    for x, y in list(combinations(A, 2)):
        if x == y:
            print("NO")
            sys.exit()

    print("YES")


if __name__ == '__main__':
    main()


# Optimized solution
import sys, re, os
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
# from fractions import gcd
from itertools import permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from functools import reduce
from bisect import bisect_left, insort_left
from heapq import heapify, heappush, heappop

INPUT = lambda: sys.stdin.readline().rstrip()
INT = lambda: int(INPUT())
MAP = lambda: list(map(int, INPUT().split()))
S_MAP = lambda: list(map(str, INPUT().split()))
LIST = lambda: list(map(int, INPUT().split()))
S_LIST = lambda: list(map(str, INPUT().split()))

sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7


def main():
    N = INT()
    A = LIST()
    b = [INF]

    for i in range(N):
        if b[bisect_left(b, A[i])] == A[i]:
            print("NO")
            sys.exit()
        else:
            insort_left(b, A[i])

    print("YES")


if __name__ == '__main__':
    main()
# Original solution
# -*- coding: utf-8 -*-
import sys

N = int(eval(input()))
A = [int(i) for i in input().split()]

for i in range(len(A)):
    a = A[i]
    for aa in A[i+1:]:
        if aa == a:
            print('NO')
            sys.exit()

print('YES')

# Optimized solution
# -*- coding: utf-8 -*-
import sys

N = int(eval(input()))
A = [int(i) for i in input().split()]

dp = {}

for a in A:
    if a-2 in dp:
        print('NO')
        break
    dp[a-2] = 1
else:
    print('YES')
# Original solution
def main():
    n = int(eval(input()))
    vals = list(map(int, input().split()))
    flg = 0
    for i in vals:
        if vals.count(i) > 1:
            flg += 1
            break
    if flg == 0:
        print('YES')
    else:
        print('NO')


if __name__ == "__main__":
    main()


# Optimized solution
def main():
    n = int(eval(input()))
    vals = list(map(int, input().split()))
    flg = 0

    vals.sort()
    for i in range(n-1):
        if vals[i] == vals[i + 1]:
            flg += 1
            break
    if flg == 0:
        print('YES')
    else:
        print('NO')


if __name__ == "__main__":
    main()
# Original solution
dic={}
n=int(eval(input()))
lis=list(map(int,input().split()))
for i in range(len(lis)):
    if dic.get(lis[i],0)==0:
        dic[lis[i]]=1
    else:
        print("NO")
        exit()
print("YES")

# Optimized solution
n=eval(input())
l=list(map(int,input().split()))
if len(l)==len(set(l)):
    print("YES")
else:print("NO")
# Original solution
N=int(eval(input()))
A=list(input().split())

X=0
for i in range(N):
    X+=A.count(A[i])

if X==N:
    print("YES")
else:
    print("NO")

# Optimized solution
N=int(eval(input()))
A=list(map(int, input().split()))
 
if len(set(A))==len(A):
    print("YES")
else:
    print("NO")
# Original solution
num = input()
list = list(map(int,input().split()))
flg  = False
for i in list:
  if list.count(i) >= 2:
    flg = True
    break
print("NO") if flg else print("YES")


# Optimized solution
num = input()
list = list(map(int,input().split()))
list2 = set(list) 
print("YES") if len(list) == len(list2) else print("NO")
# Original solution
# -*- coding:utf-8 -*-
n = int(eval(input()))
numbers = []

for i in map(int,input().split()):
  numbers.append(i)

a = sorted(list(set(numbers)))
b = sorted(numbers)
  
if a == b:
  print("YES")
else:
  print("NO")

# Optimized solution
n = int(eval(input()))
a = list(map(int, input().split()))

b = list(set(a))

if sorted(a) == sorted(b):
  print('YES')
else:
  print('NO')
# Original solution
def merge(array):
    mid = len(array)
    if mid > 1:
        mid = mid // 2
        left = merge(array[:mid])
        right = merge(array[mid:])
        array = []
        while len(left) != 0 and len(right) != 0:
            if left[0] == right[0]:
                print("NO")
                exit()
            elif left[0] < right[0]:
                array.append(left.pop(0))
            else:
                array.append(right.pop(0))
        if len(left) != 0:
            array.extend(left)
        elif len(right) != 0:
            array.extend(right)
    return array

n = int(eval(input()))
a = list(map(int, input().split()))
a.sort()
merge(a)
print("YES")

# Optimized solution
N = int(eval(input()))
A = list(map(int, input().split()))
ans = {}
flag = 0

for i in A:
    if (ans.get(i) != None):
        flag = 1
        break
    else:
        ans[i] = 1

if (flag == 0):
    print("YES")
else:
    print("NO")
# Original solution
n = int(eval(input()))
a = list(input().split())
for i in range(n):
  for k in range(i+1,n):
    if a[i] == a[k]:
      print("NO")
      exit()
print("YES")

# Optimized solution
n = int(eval(input()))
a = list(input().split())
if n == len(list(set(a))):
  print("YES")
else:
  print("NO")
# Original solution
import sys
N = int(eval(input()))

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

numbers = []
for i in range(N):
    if a[i] not in numbers:
        numbers.append(a[i])
    elif a[i] in numbers:
        print('NO')
        sys.exit()
print('YES')

# Optimized solution
import sys
N = int(eval(input()))

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

a.sort()

numbers = []
for i in range(N-1):
    if a[i] == a[i+1]:
        print('NO')
        sys.exit()
print('YES')
# Original solution
N = int(eval(input()))

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

for num in nums:
    if nums.count(num) >= 2:
        print("NO")
        break
else:
    print("YES")

# Optimized solution
N = int(eval(input()))

nums = tuple(map(int, input().split()))

if len(nums) == len(set(nums)):
    print("YES")
else:
    print("NO")
# Original solution
n=int(eval(input()))
a=list(map(int,input().split()))
a=sorted(a)
for i in a:
    if a.count(i)>1:
        print('NO')
        exit()
        
print('YES')        
        

# Optimized solution
n=int(eval(input()))
a=list(map(int,input().split()))
b=set(a)

if len(a)==len(b):
    print('YES')
else:
    print('NO')
# Original solution
n = int(eval(input()))
a = list(map(int, input().split()))

flag = 1
for i in range(n):
    if flag == 0:
        break
    for j in range(i+1, n):
        if a[i] == a[j]:
            flag = 0
            break

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

# Optimized solution
n = int(eval(input()))
a = list(map(int, input().split()))

flag = 1
a.sort()
for i in range(n-1):
    if a[i] == a[i+1]:
        flag = 0
        break
    
if flag == 1:
    print("YES")
else:
    print("NO")
# Original solution
def pairwise_distinct():
    n = int(eval(input()))
    k = list(input().split())
    if (len(set(k)) == len(k)):
        return "YES"
    else:
        return "NO"

print((pairwise_distinct()))

# Optimized solution
def pairwise_distinct():
    n = int(eval(input()))
    k = list(input().split()) #input based on n
    if not len(k) == n:
        return "==== pleas input based on n times in one line ===="
    else:
        if (len(set(k)) == len(k)):
            return "YES"
        else:
            return "NO"

print((pairwise_distinct()))
# Original solution
import collections

n = int(eval(input()))
a = list(map(int,input().split()))
s = collections.deque()

for i in a:
    if i not in s:
        s.appendleft(i)
    else:
        print("NO")
        exit()

print("YES")

# Optimized solution
import collections

n = int(eval(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")
# Original solution
import sys
a=int(eval(input()))
b=list(map(int,input().split()))

for i in range(a):
  for j in range(a):
    if i==j:
      pass
    else:
      
      if b[j]==b[i]:
        print('NO')
        sys.exit()
print('YES')

# Optimized solution
a=int(eval(input()))
b=list(map(int,input().split()))
d=len(b)
c=len(set(b))
if c==d:
  print('YES')
else:
  print('NO')
# Original solution
def solve():
    N = int(eval(input()))
    array = list(map(int, input().split()))
    for each in array:
        if array.count(each) > 1:
            print("NO")
            return
    print("YES")

solve()

# Optimized solution
def solve():
    N = int(eval(input()))
    array = sorted(map(int, input().split()))
    for index in range(1, N):
        if array[index] == array[index - 1]:
            print("NO")
            return
    print("YES")
solve()
# Original solution
num = int(eval(input()))
line = [int(a) for a in input().split()]

for i in range(num):
    if line[i] in line[i+1:]:
        print('NO')
        break
else:
    print('YES')

# Optimized solution
num = int(eval(input()))
line = [int(a) for a in input().split()]
set_line = list(set(line))

if len(line) == len(set_line):
    print('YES')
else:
    print('NO')
# Original solution
n = int(eval(input()))
a = list(map(int,input().split()))
for i,b in enumerate(a):
    for j in range(i+1,n):
        #print(b,a[j])
        if b == a[j]:
            print('NO')
            exit()
print('YES')


# Optimized solution
n = int(eval(input()))
a = list(map(int,input().split()))
if n == len(set(a)):
  print('YES')
else:
  print('NO')
# Original solution
n = int(eval(input()))
lst = list(map(int, input().split()))
lst2 =[]
maxval2 = 0
flag = 0
maxval = max(lst)
for _ in range(n-1):
  lst.pop(lst.index(maxval))
  maxval2 = max(lst)
  if maxval == maxval2:
    print('NO')
    flag = 1
    break
  maxval = maxval2
if flag == 0:
  print('YES')


# Optimized solution
n = int(eval(input()))
lst = list(map(int, input().split()))
flag = 0
lst.sort()
for i in range(n-1):
  if lst[i] == lst[i+1]:
    print('NO')
    flag = 1
    break
if flag == 0:
  print('YES')
# Original solution
N = int(eval(input()))
A = [int(x) for x in input().split()]
C =[]
for i in A:
    count = 0
    for j in A:
        if i == j:
            count += 1
        if count == 2:
            C.append('NO')
            break
        else:
            C.append('YES')
if 'NO' in C :
    print('NO')
else:
    print('YES')

# Optimized solution
N = int(eval(input()))
A = [int(x) for x in input().split()]
B = sorted(A)
NO = False
for i in range(0,len(B)-1):
    if B[i+1] - B[i] == 0:
        NO = True
if NO == True:
    print('NO')
else:
    print('YES')
# Original solution
m = eval(input())
N = list(map(int, input().split(' ')))
# m = int(input())
# k = int(input())
c = 0
N.sort()
for i in N:
    
    if N.count(i) > 1:
        c = 1
        break
if c == 0:
    print('YES')
else:
    print('NO')

# Optimized solution
m = eval(input())
N = list(map(int, input().split(' ')))
# m = int(input())
# k = int(input())
c = 0
N.sort()
for i in range(len(N)-1):
    if N[i] == N[i+1]:
        print('NO')
        exit()

print('YES')
# Original solution
import sys
n = int(eval(input()))
a = [int(a) for a in input().split()]

for i in range(n):
  if a.count(a[i]) > 1:
    print('NO')
    sys.exit()

print('YES')

# Optimized solution
import sys
n = int(eval(input()))
a = [int(a) for a in input().split()]

done = {}
flag = 0
for i in range(n):
  try:
    if done[a[i]] > 0:
      flag = 1
    done[a[i]] = 1
  except:
    done[a[i]] = 1

if flag:
  print('NO')
else:
  print('YES')
# Original solution
n, *a = list(map(int, open(0).read().split()))
print(("YNEOS"[len(set(a))!=len(a)::2]))

# Optimized solution
n=int(eval(input()));print(("YNEOS"[n!=len(set(input().split()))::2]))
# Original solution
n=int(eval(input()));print(("YNEOS"[n!=len(set(input().split()))::2]))

# Optimized solution
print(("YNEOS"[int(eval(input()))!=len(set(input().split()))::2]))
# Original solution
N=int(eval(input()))
A=list(input().split())
ans='YES'
for i in range(N):
  if A.count(A[i])>=2:
    ans='NO'
    break
print(ans)

# Optimized solution
N=int(eval(input()))
A=list(input().split())
B=list(set(A))
ans='YES'
if len(A)!=len(B):
  ans='NO'   
print(ans)
# Original solution
import sys

def binary_search(li, item):
  low = 0
  high = len(li) - 1
  
  while low <= high:
    mid = (low + high) // 2
    guess = li[mid]
    if item == guess:
      return True
    if item < guess:
      high = mid-1
    else:
      low = mid+1
  return False

def main():
  input = sys.stdin.readline
  n = int(eval(input()))
  a_li = list(input().split())
  a_li = [int(s) for s in a_li]

  a_li.sort()
  for a in a_li:
    a_li.remove(a)
    if binary_search(a_li, a) == True:
      print("NO")
      sys.exit()
  print("YES")
  
if __name__ == "__main__":
  main()

# Optimized solution
import sys


def main():
  input = sys.stdin.readline
  n = int(eval(input()))
  a_li = list(input().split())
  a_li = [int(s) for s in a_li]

  a_li.sort()
  for i in range(n-1):
    if a_li[i] == a_li[i+1]:
      print("NO")
      sys.exit()
  print("YES")
  
if __name__ == "__main__":
  main()