object Main extends App {
	val sc = new java.util.Scanner(System.in)
	val pw = new java.io.PrintWriter(System.out)
	
	@scala.annotation.tailrec
	def isDistinct(a: Seq[Int], r: Boolean): Boolean = a match {
		case Seq()   => r
		case x +: xs => isDistinct(xs, xs.forall(x != _) && r)
	}
	
	pw.println(if (isDistinct(Seq.fill(sc.nextInt)(sc.nextInt), true)) "YES" else "NO")
	pw.flush()
}