def main():
    n = int(input())
    inlis = list(map(int, input().split()))
    inset = set(inlis)

    if len(inlis) == len(inset):
        print("YES")
    else:
        print("NO")
    
    
if __name__ == "__main__":
    main() def main():
    n = int(input())
    inlis = list(map(int, input().split()))
    inset = set(inlis)

    if len(inlis) == len(inset):
        print("YES")
    else:
        print("NO")
    
     main n = int(input()) n int(input()) int input() input inlis = list(map(int, input().split())) inlis list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split inset = set(inlis) inset set(inlis) set inlis if len(inlis) == len(inset):
        print("YES")
    else:
        print("NO")
    
     len(inlis) == len(inset) len(inlis) len inlis len(inset) len inset print("YES") print "YES" print("NO") print "NO" if __name__ == "__main__":
    main() __name__ == "__main__" __name__ "__main__" main() main def main():
    n = int(input())
    inlis = list(map(int, input().split()))
    inset = set(inlis)

    if len(inlis) == len(inset):
        print("YES")
    else:
        print("NO")
    
     def main():
    n = int(input())
    inlis = list(map(int, input().split()))
    inset = set(inlis)

    if len(inlis) == len(inset):
        print("YES")
    else:
        print("NO")
    
     main
def main():
    n = int(input())
    inlis = list(map(int, input().split()))
    inset = set(inlis)

    if len(inlis) == len(inset):
        print("YES")
    else:
        print("NO")
    
    
if __name__ == "__main__":
    main()
