from typing import List


def main():
    n = int(input())
    nums = input().split(' ')
    r = don(n, nums)
    if r:
        print('YES')
    else:
        print('NO')


def don(n: int, nums: List[str]) -> bool:
    s = set()
    result = True

    for i in range(n):
        num = nums[i]
        if num in s:
            result = False
            break
        s.add(num)

    return result


if __name__ == '__main__':
    main() from typing import List def main():
    n = int(input())
    nums = input().split(' ')
    r = don(n, nums)
    if r:
        print('YES')
    else:
        print('NO') main n = int(input()) n int(input()) int input() input nums = input().split(' ') nums input().split(' ') ().split () input split ' ' r = don(n, nums) r don(n, nums) don n nums if r:
        print('YES')
    else:
        print('NO') r print('YES') print 'YES' print('NO') print 'NO' def don(n: int, nums: List[str]) -> bool:
    s = set()
    result = True

    for i in range(n):
        num = nums[i]
        if num in s:
            result = False
            break
        s.add(num)

    return result don s = set() s set() set result = True result True for i in range(n):
        num = nums[i]
        if num in s:
            result = False
            break
        s.add(num)

     i range(n) range n num = nums[i] num nums[i] nums i if num in s:
            result = False
            break
         num in s num s result = False result False break s.add(num) s.add s add num return result result n: int n nums: List[str] nums if __name__ == '__main__':
    main() __name__ == '__main__' __name__ '__main__' main() main def main():
    n = int(input())
    nums = input().split(' ')
    r = don(n, nums)
    if r:
        print('YES')
    else:
        print('NO') def main():
    n = int(input())
    nums = input().split(' ')
    r = don(n, nums)
    if r:
        print('YES')
    else:
        print('NO') main def don(n: int, nums: List[str]) -> bool:
    s = set()
    result = True

    for i in range(n):
        num = nums[i]
        if num in s:
            result = False
            break
        s.add(num)

    return result def don(n: int, nums: List[str]) -> bool:
    s = set()
    result = True

    for i in range(n):
        num = nums[i]
        if num in s:
            result = False
            break
        s.add(num)

    return result don
from typing import List


def main():
    n = int(input())
    nums = input().split(' ')
    r = don(n, nums)
    if r:
        print('YES')
    else:
        print('NO')


def don(n: int, nums: List[str]) -> bool:
    s = set()
    result = True

    for i in range(n):
        num = nums[i]
        if num in s:
            result = False
            break
        s.add(num)

    return result


if __name__ == '__main__':
    main()
