import java.util.*

fun main(args: Array<String>) {
    val scn = Scanner(System.`in`)
    val N = scn.nextInt()

    var map = mutableMapOf<Int, Int?>()
    var ans = true
    for(i in 1..N){
        val A = scn.nextInt()
        if(map.containsKey(A)){
            map[A] = map[A]?.plus(1)
            ans = false
        }else{
            map.put(A,1)
        }
    }

    if(ans) {
        println("YES")
    }else{
        println("NO")
    }
}