#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*/ puts(char *);
scalar_t__ scanf(char *, int *, ...);
int main() {
  int l, n, h, w;
  scanf("%d", &l);
  scanf("%d", &n);
  for (int a = 1; a <= n && scanf("%d %d", &h, &w); a++) {
    if ((h < l) || (w < l))
      puts("UPLOAD ANOTHER");
    else {
      if (h == w)
        puts("ACCEPTED");
      else
        puts("CROP IT");
    }
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xecd(%rip),%rdi
lea    -0x8(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
lea    0xebb(%rip),%rdi
lea    -0xc(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
movl   $0x1,-0x18(%rbp)
mov    -0x18(%rbp),%ecx
xor    %eax,%eax
cmp    -0xc(%rbp),%ecx
mov    %al,-0x19(%rbp)
jg     118b <main+0x6b>
lea    0xe8e(%rip),%rdi
lea    -0x10(%rbp),%rsi
lea    -0x14(%rbp),%rdx
mov    $0x0,%al
call   1040 <scanf@plt>
cmp    $0x0,%rax
setne  %al
mov    %al,-0x19(%rbp)
mov    -0x19(%rbp),%al
test   $0x1,%al
jne    119b <main+0x7b>
jmp    1205 <main+0xe5>
mov    -0x10(%rbp),%eax
cmp    -0x8(%rbp),%eax
jl     11b3 <main+0x93>
mov    -0x14(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    11c4 <main+0xa4>
lea    0xe4c(%rip),%rdi
call   1030 <puts@plt>
jmp    11f2 <main+0xd2>
mov    -0x10(%rbp),%eax
cmp    -0x14(%rbp),%eax
jne    11e1 <main+0xc1>
lea    0xe3e(%rip),%rdi
call   1030 <puts@plt>
jmp    11ed <main+0xcd>
lea    0xe36(%rip),%rdi
call   1030 <puts@plt>
jmp    11f2 <main+0xd2>
jmp    11f7 <main+0xd7>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    115a <main+0x3a>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
lea    0xece(%rip),%rbx
lea    0x14(%rsp),%rsi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <scanf@plt>
lea    0x8(%rsp),%rsi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <scanf@plt>
cmpl   $0x0,0x8(%rsp)
jle    11cd <main+0xad>
lea    0xe9f(%rip),%r14
lea    0x10(%rsp),%r15
lea    0xc(%rsp),%r12
lea    0xe94(%rip),%rbx
lea    0xe9c(%rip),%r13
xor    %ebp,%ebp
jmp    118e <main+0x6e>
nopl   (%rax)
call   1030 <puts@plt>
add    $0x1,%ebp
cmp    0x8(%rsp),%ebp
jge    11cd <main+0xad>
mov    %r14,%rdi
mov    %r15,%rsi
mov    %r12,%rdx
xor    %eax,%eax
call   1040 <scanf@plt>
test   %rax,%rax
je     11cd <main+0xad>
mov    0x10(%rsp),%eax
mov    0x14(%rsp),%ecx
mov    %rbx,%rdi
cmp    %ecx,%eax
jl     1180 <main+0x60>
mov    0xc(%rsp),%edx
mov    %rbx,%rdi
cmp    %ecx,%edx
jl     1180 <main+0x60>
mov    %r13,%rdi
cmp    %edx,%eax
je     1180 <main+0x60>
lea    0xe53(%rip),%rdi
jmp    1180 <main+0x60>
xor    %eax,%eax
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [6 x i8] c"%d %d\00"
@.str.2 = [15 x i8] c"UPLOAD ANOTHER\00"
@.str.3 = [9 x i8] c"ACCEPTED\00"
@.str.4 = [8 x i8] c"CROP IT\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
store i32 0, i32* %1
%7 = call i64 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
%8 = call i64 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %3)
store i32 1, i32* %6
br label %9
9: ; preds = %38, %0
%10 = load i32, i32* %6
%11 = load i32, i32* %3
%12 = icmp sle i32 %10, %11
br i1 %12, label %13, label %16
13: ; preds = %9
%14 = call i64 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), i32* %4, i32* %5)
%15 = icmp ne i64 %14, 0
br label %16
16: ; preds = %13, %9
%17 = phi i1 [ false, %9 ], [ %15, %13 ]
br i1 %17, label %18, label %41
18: ; preds = %16
%19 = load i32, i32* %4
%20 = load i32, i32* %2
%21 = icmp slt i32 %19, %20
br i1 %21, label %26, label %22
22: ; preds = %18
%23 = load i32, i32* %5
%24 = load i32, i32* %2
%25 = icmp slt i32 %23, %24
br i1 %25, label %26, label %28
26: ; preds = %22, %18
%27 = call i32 @puts(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.2, i64 0, i64 0))
br label %37
28: ; preds = %22
%29 = load i32, i32* %4
%30 = load i32, i32* %5
%31 = icmp eq i32 %29, %30
br i1 %31, label %32, label %34
32: ; preds = %28
%33 = call i32 @puts(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.3, i64 0, i64 0))
br label %36
34: ; preds = %28
%35 = call i32 @puts(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.4, i64 0, i64 0))
br label %36
36: ; preds = %34, %32
br label %37
37: ; preds = %36, %26
br label %38
38: ; preds = %37
%39 = load i32, i32* %6
%40 = add nsw i32 %39, 1
store i32 %40, i32* %6
br label %9
41: ; preds = %16
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [6 x i8] c"%d %d\00"
@.str.2 = [15 x i8] c"UPLOAD ANOTHER\00"
@.str.3 = [9 x i8] c"ACCEPTED\00"
@.str.4 = [8 x i8] c"CROP IT\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = bitcast i32* %1 to i8*
%6 = bitcast i32* %2 to i8*
%7 = bitcast i32* %3 to i8*
%8 = bitcast i32* %4 to i8*
%9 = call i64 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
%10 = call i64 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
%11 = load i32, i32* %2
%12 = icmp slt i32 %11, 1
br i1 %12, label %17, label %13
13: ; preds = %0, %28
%14 = phi i32 [ %31, %28 ], [ 1, %0 ]
%15 = call i64 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), i32* %3, i32* %4)
%16 = icmp eq i64 %15, 0
br i1 %16, label %17, label %18
17: ; preds = %13, %28, %0
ret i32 0
18: ; preds = %13
%19 = load i32, i32* %3
%20 = load i32, i32* %1
%21 = icmp slt i32 %19, %20
br i1 %21, label %28, label %22
22: ; preds = %18
%23 = load i32, i32* %4
%24 = icmp slt i32 %23, %20
br i1 %24, label %28, label %25
25: ; preds = %22
%26 = icmp eq i32 %19, %23
%27 = select i1 %26, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.4, i64 0, i64 0)
br label %28
28: ; preds = %25, %18, %22
%29 = phi i8* [ getelementptr inbounds ([15 x i8], [15 x i8]* @.str.2, i64 0, i64 0), %22 ], [ getelementptr inbounds ([15 x i8], [15 x i8]* @.str.2, i64 0, i64 0), %18 ], [ %27, %25 ]
%30 = call i32 @puts(i8* dereferenceable(1) %29)
%31 = add nuw nsw i32 %14, 1
%32 = load i32, i32* %2
%33 = icmp slt i32 %14, %32
br i1 %33, label %13, label %17
}