#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int n, j, p, i;
  scanf("%d\n", &n);
  int a[n];
  for (i = 0; i < n; i++) {
    scanf("%d", &a[i]);
  }
  for (j = 0; j < n - 1; j++) {
    for (p = j + 1; p < n; p++) {
      if (a[j] == a[p])
        printf("YES");
      break;
      if (j == n - 2) {
        printf("NO");
      }
    }
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1040 <scanf@plt>
mov    -0x8(%rbp),%eax
mov    %rsp,%rcx
mov    %rcx,-0x20(%rbp)
lea    0xf(,%rax,4),%rdx
and    $0xfffffffffffffff0,%rdx
mov    %rsp,%rcx
sub    %rdx,%rcx
mov    %rcx,-0x30(%rbp)
mov    %rcx,%rsp
mov    %rax,-0x28(%rbp)
movl   $0x0,-0x14(%rbp)
mov    -0x14(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    11a2 <main+0x82>
mov    -0x30(%rbp),%rsi
movslq -0x14(%rbp),%rax
shl    $0x2,%rax
add    %rax,%rsi
lea    0xe75(%rip),%rdi
call   1040 <scanf@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    116d <main+0x4d>
movl   $0x0,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    -0x8(%rbp),%ecx
sub    $0x1,%ecx
cmp    %ecx,%eax
jge    120b <main+0xeb>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    11f8 <main+0xd8>
mov    -0x30(%rbp),%rcx
movslq -0xc(%rbp),%rax
mov    (%rcx,%rax,4),%eax
movslq -0x10(%rbp),%rdx
cmp    (%rcx,%rdx,4),%eax
jne    11f3 <main+0xd3>
lea    0xe19(%rip),%rdi
call   1030 <printf@plt>
jmp    11f8 <main+0xd8>
jmp    11fd <main+0xdd>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    11a9 <main+0x89>
movl   $0x0,-0x4(%rbp)
mov    -0x20(%rbp),%rax
mov    %rax,%rsp
mov    -0x4(%rbp),%eax
mov    %rbp,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
lea    0xecb(%rip),%rdi
lea    -0x2c(%rbp),%rsi
call   1040 <scanf@plt>
mov    %rsp,%r15
mov    -0x2c(%rbp),%eax
mov    %rsp,%r12
lea    0xf(,%rax,4),%rax
and    $0xfffffffffffffff0,%rax
sub    %rax,%r12
mov    %r12,%rsp
cmpl   $0x0,-0x2c(%rbp)
jle    11d2 <main+0xb2>
xor    %r13d,%r13d
lea    0xe9b(%rip),%r14
mov    %r12,%rbx
nopl   0x0(%rax)
mov    %r14,%rdi
mov    %rbx,%rsi
call   1040 <scanf@plt>
add    $0x1,%r13
movslq -0x2c(%rbp),%rax
add    $0x4,%rbx
cmp    %rax,%r13
jl     1170 <main+0x50>
cmp    $0x2,%eax
jl     11d2 <main+0xb2>
mov    $0x1,%ebx
lea    0xe6a(%rip),%r14
jmp    11b2 <main+0x92>
nop
lea    -0x1(%rax),%ecx
movslq %ecx,%rcx
lea    0x1(%rbx),%rdx
cmp    %rcx,%rbx
mov    %rdx,%rbx
jge    11d2 <main+0xb2>
movslq %eax,%rcx
cmp    %rcx,%rbx
jge    11a0 <main+0x80>
mov    -0x4(%r12,%rbx,4),%ecx
cmp    (%r12,%rbx,4),%ecx
jne    11a0 <main+0x80>
mov    %r14,%rdi
call   1030 <printf@plt>
mov    -0x2c(%rbp),%eax
jmp    11a0 <main+0x80>
mov    %r15,%rsp
xor    %eax,%eax
lea    -0x28(%rbp),%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [4 x i8] c"%d\0A\00"
@.str.1 = [3 x i8] c"%d\00"
@.str.2 = [4 x i8] c"YES\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i8*
%7 = alloca i64
store i32 0, i32* %1
%8 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32* %2)
%9 = load i32, i32* %2
%10 = zext i32 %9 to i64
%11 = call i8* @llvm.stacksave()
store i8* %11, i8** %6
%12 = alloca i32, i64 %10
store i64 %10, i64* %7
store i32 0, i32* %5
br label %13
13: ; preds = %22, %0
%14 = load i32, i32* %5
%15 = load i32, i32* %2
%16 = icmp slt i32 %14, %15
br i1 %16, label %17, label %25
17: ; preds = %13
%18 = load i32, i32* %5
%19 = sext i32 %18 to i64
%20 = getelementptr inbounds i32, i32* %12, i64 %19
%21 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %20)
br label %22
22: ; preds = %17
%23 = load i32, i32* %5
%24 = add nsw i32 %23, 1
store i32 %24, i32* %5
br label %13
25: ; preds = %13
store i32 0, i32* %3
br label %26
26: ; preds = %55, %25
%27 = load i32, i32* %3
%28 = load i32, i32* %2
%29 = sub nsw i32 %28, 1
%30 = icmp slt i32 %27, %29
br i1 %30, label %31, label %58
31: ; preds = %26
%32 = load i32, i32* %3
%33 = add nsw i32 %32, 1
store i32 %33, i32* %4
br label %34
34: ; preds = %51, %31
%35 = load i32, i32* %4
%36 = load i32, i32* %2
%37 = icmp slt i32 %35, %36
br i1 %37, label %38, label %54
38: ; preds = %34
%39 = load i32, i32* %3
%40 = sext i32 %39 to i64
%41 = getelementptr inbounds i32, i32* %12, i64 %40
%42 = load i32, i32* %41
%43 = load i32, i32* %4
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds i32, i32* %12, i64 %44
%46 = load i32, i32* %45
%47 = icmp eq i32 %42, %46
br i1 %47, label %48, label %50
48: ; preds = %38
%49 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0))
br label %50
50: ; preds = %48, %38
br label %54
51: ; No predecessors!
%52 = load i32, i32* %4
%53 = add nsw i32 %52, 1
store i32 %53, i32* %4
br label %34
54: ; preds = %50, %34
br label %55
55: ; preds = %54
%56 = load i32, i32* %3
%57 = add nsw i32 %56, 1
store i32 %57, i32* %3
br label %26
58: ; preds = %26
store i32 0, i32* %1
%59 = load i8*, i8** %6
%60 = load i32, i32* %1
ret i32 %60
}

LLVM IR (-O2):
@.str = [4 x i8] c"%d\0A\00"
@.str.1 = [3 x i8] c"%d\00"
@.str.2 = [4 x i8] c"YES\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32* %1)
%4 = load i32, i32* %1
%5 = zext i32 %4 to i64
%6 = call i8* @llvm.stacksave()
%7 = alloca i32, i64 %5
%8 = load i32, i32* %1
%9 = icmp sgt i32 %8, 0
br i1 %9, label %12, label %40
10: ; preds = %12
%11 = icmp sgt i32 %17, 1
br i1 %11, label %20, label %40
12: ; preds = %0, %12
%13 = phi i64 [ %16, %12 ], [ 0, %0 ]
%14 = getelementptr inbounds i32, i32* %7, i64 %13
%15 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %14)
%16 = add nuw nsw i64 %13, 1
%17 = load i32, i32* %1
%18 = sext i32 %17 to i64
%19 = icmp slt i64 %16, %18
br i1 %19, label %12, label %10
20: ; preds = %10, %35
%21 = phi i32 [ %36, %35 ], [ %17, %10 ]
%22 = phi i64 [ %23, %35 ], [ 0, %10 ]
%23 = add nuw nsw i64 %22, 1
%24 = sext i32 %21 to i64
%25 = icmp slt i64 %23, %24
br i1 %25, label %26, label %35
26: ; preds = %20
%27 = getelementptr inbounds i32, i32* %7, i64 %22
%28 = load i32, i32* %27
%29 = getelementptr inbounds i32, i32* %7, i64 %23
%30 = load i32, i32* %29
%31 = icmp eq i32 %28, %30
br i1 %31, label %32, label %35
32: ; preds = %26
%33 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0))
%34 = load i32, i32* %1
br label %35
35: ; preds = %20, %32, %26
%36 = phi i32 [ %21, %20 ], [ %34, %32 ], [ %21, %26 ]
%37 = add nsw i32 %36, -1
%38 = sext i32 %37 to i64
%39 = icmp slt i64 %23, %38
br i1 %39, label %20, label %40
40: ; preds = %35, %0, %10
ret i32 0
}