def resolve():
    N = int(input())
    A = list(map(int, input().split()))
    print("YES" if len(A) == len(set(A)) else "NO")

if '__main__' == __name__:
    resolve() def resolve():
    N = int(input())
    A = list(map(int, input().split()))
    print("YES" if len(A) == len(set(A)) else "NO") resolve 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 print("YES" if len(A) == len(set(A)) else "NO") print "YES" if len(A) == len(set(A)) else "NO" len(A) == len(set(A)) len(A) len A len(set(A)) len set(A) set A "YES" "NO" if '__main__' == __name__:
    resolve() '__main__' == __name__ '__main__' __name__ resolve() resolve def resolve():
    N = int(input())
    A = list(map(int, input().split()))
    print("YES" if len(A) == len(set(A)) else "NO") def resolve():
    N = int(input())
    A = list(map(int, input().split()))
    print("YES" if len(A) == len(set(A)) else "NO") resolve
def resolve():
    N = int(input())
    A = list(map(int, input().split()))
    print("YES" if len(A) == len(set(A)) else "NO")

if '__main__' == __name__:
    resolve()