from collections import defaultdict
import sys
N = int(input())

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

C = defaultdict(int)

for a in A:
  C[a] += 1
  if C[a] >= 2:
    print('NO')
    sys.exit()

print('YES') from collections import defaultdict import sys sys N = int(input()) N int(input()) int input() input A = list(map(int, input().split())) A list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split C = defaultdict(int) C defaultdict(int) defaultdict int for a in A:
  C[a] += 1
  if C[a] >= 2:
    print('NO')
    sys.exit() a A C[a] += 1 C[a] C a 1 if C[a] >= 2:
    print('NO')
    sys.exit() C[a] >= 2 C[a] C a 2 print('NO') print 'NO' sys.exit() sys.exit sys exit print('YES') print 'YES' A = list(map(int, input().split())) list(map(int, input().split())) A C = defaultdict(int) defaultdict(int) C N = int(input()) int(input()) N
from collections import defaultdict
import sys
N = int(input())

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

C = defaultdict(int)

for a in A:
  C[a] += 1
  if C[a] >= 2:
    print('NO')
    sys.exit()

print('YES')