function main(input) {
    var s = input[1].split(" ");
    var ans = true;
    var map = {};
    s.forEach(v=>{
        if(map[v]) ans = false;
        map[v] = true;
    })
    console.log(ans?"YES":"NO");
}
main(require('fs').readFileSync('/dev/stdin', 'utf8').trim().split("\n"))
