def solve():
    n = int(input())
    s = list(map(int, input().split()))
    t = set(s)
    print("YES" if len(s) == len(t) else "NO")


solve() def solve():
    n = int(input())
    s = list(map(int, input().split()))
    t = set(s)
    print("YES" if len(s) == len(t) else "NO") solve n = int(input()) n int(input()) int input() input s = list(map(int, input().split())) s list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split t = set(s) t set(s) set s print("YES" if len(s) == len(t) else "NO") print "YES" if len(s) == len(t) else "NO" len(s) == len(t) len(s) len s len(t) len t "YES" "NO" solve() solve def solve():
    n = int(input())
    s = list(map(int, input().split()))
    t = set(s)
    print("YES" if len(s) == len(t) else "NO") def solve():
    n = int(input())
    s = list(map(int, input().split()))
    t = set(s)
    print("YES" if len(s) == len(t) else "NO") solve
def solve():
    n = int(input())
    s = list(map(int, input().split()))
    t = set(s)
    print("YES" if len(s) == len(t) else "NO")


solve()
