"use strict";
    
const main = arg => {
    arg = arg.trim().split("\n");
    const N = parseInt(arg[0])
    const S = arg[1].split(" ").map(n=>parseInt(n));
    
    const set = new Set(S);
    
    console.log(set.size === N ? "YES" : "NO");
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));