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


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


solve()
