import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.*; public class Main { public static Scanner sc = new Scanner(System.in); public static BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); public static void main(String[] args) throws Exception { int n = sc.nextInt(); int[] arr = new int[n]; for(int i=0;i<n;i++) { arr[i] = sc.nextInt(); } boolean flag = false; Arrays.sort(arr); int lastVal = arr[0]; for(int i=1;i<n;i++){ if(arr[i] == lastVal){ flag = true; break; }else { lastVal = arr[i]; } } System.out.println(flag ? "NO" : "YES"); } } /* */