#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, int);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int N[20];
  for (int i = 0; i < 20; i++)
    scanf("%d", &N[i]);
  for (int i = 0; i < 20; i++)
    printf("N[%d] = %d\n", i, N[19 - i]);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x64(%rbp)
cmpl   $0x14,-0x64(%rbp)
jge    1169 <main+0x49>
movslq -0x64(%rbp),%rax
lea    -0x60(%rbp),%rsi
shl    $0x2,%rax
add    %rax,%rsi
lea    0xeaa(%rip),%rdi
call   1040 <scanf@plt>
mov    -0x64(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x64(%rbp)
jmp    1136 <main+0x16>
movl   $0x0,-0x68(%rbp)
cmpl   $0x14,-0x68(%rbp)
jge    11a5 <main+0x85>
mov    -0x68(%rbp),%esi
mov    $0x13,%eax
sub    -0x68(%rbp),%eax
cltq
mov    -0x60(%rbp,%rax,4),%edx
lea    0xe71(%rip),%rdi
call   1030 <printf@plt>
mov    -0x68(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x68(%rbp)
jmp    1170 <main+0x50>
xor    %eax,%eax
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x50,%rsp
lea    0xed4(%rip),%rbx
mov    %rsp,%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x4(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x8(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0xc(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x10(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x14(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x18(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x1c(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x20(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x24(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x28(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x2c(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x30(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x34(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x38(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x3c(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x40(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x44(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x48(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
lea    0x4c(%rsp),%rsi
mov    %rbx,%rdi
call   1040 <scanf@plt>
mov    0x4c(%rsp),%edx
lea    0xdca(%rip),%rbx
mov    %rbx,%rdi
xor    %esi,%esi
call   1030 <printf@plt>
mov    0x48(%rsp),%edx
mov    %rbx,%rdi
mov    $0x1,%esi
call   1030 <printf@plt>
mov    0x44(%rsp),%edx
mov    %rbx,%rdi
mov    $0x2,%esi
call   1030 <printf@plt>
mov    0x40(%rsp),%edx
mov    %rbx,%rdi
mov    $0x3,%esi
call   1030 <printf@plt>
mov    0x3c(%rsp),%edx
mov    %rbx,%rdi
mov    $0x4,%esi
call   1030 <printf@plt>
mov    0x38(%rsp),%edx
mov    %rbx,%rdi
mov    $0x5,%esi
call   1030 <printf@plt>
mov    0x34(%rsp),%edx
mov    %rbx,%rdi
mov    $0x6,%esi
call   1030 <printf@plt>
mov    0x30(%rsp),%edx
mov    %rbx,%rdi
mov    $0x7,%esi
call   1030 <printf@plt>
mov    0x2c(%rsp),%edx
mov    %rbx,%rdi
mov    $0x8,%esi
call   1030 <printf@plt>
mov    0x28(%rsp),%edx
mov    %rbx,%rdi
mov    $0x9,%esi
call   1030 <printf@plt>
mov    0x24(%rsp),%edx
mov    %rbx,%rdi
mov    $0xa,%esi
call   1030 <printf@plt>
mov    0x20(%rsp),%edx
mov    %rbx,%rdi
mov    $0xb,%esi
call   1030 <printf@plt>
mov    0x1c(%rsp),%edx
mov    %rbx,%rdi
mov    $0xc,%esi
call   1030 <printf@plt>
mov    0x18(%rsp),%edx
mov    %rbx,%rdi
mov    $0xd,%esi
call   1030 <printf@plt>
mov    0x14(%rsp),%edx
mov    %rbx,%rdi
mov    $0xe,%esi
call   1030 <printf@plt>
mov    0x10(%rsp),%edx
mov    %rbx,%rdi
mov    $0xf,%esi
call   1030 <printf@plt>
mov    0xc(%rsp),%edx
mov    %rbx,%rdi
mov    $0x10,%esi
call   1030 <printf@plt>
mov    0x8(%rsp),%edx
mov    %rbx,%rdi
mov    $0x11,%esi
call   1030 <printf@plt>
mov    0x4(%rsp),%edx
mov    %rbx,%rdi
mov    $0x12,%esi
call   1030 <printf@plt>
mov    (%rsp),%edx
mov    %rbx,%rdi
mov    $0x13,%esi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x50,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [12 x i8] c"N[%d] = %d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [20 x i32]
%3 = alloca i32
%4 = alloca i32
store i32 0, i32* %1
store i32 0, i32* %3
br label %5
5: ; preds = %13, %0
%6 = load i32, i32* %3
%7 = icmp slt i32 %6, 20
br i1 %7, label %8, label %16
8: ; preds = %5
%9 = load i32, i32* %3
%10 = sext i32 %9 to i64
%11 = getelementptr inbounds [20 x i32], [20 x i32]* %2, i64 0, i64 %10
%12 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %11)
br label %13
13: ; preds = %8
%14 = load i32, i32* %3
%15 = add nsw i32 %14, 1
store i32 %15, i32* %3
br label %5
16: ; preds = %5
store i32 0, i32* %4
br label %17
17: ; preds = %28, %16
%18 = load i32, i32* %4
%19 = icmp slt i32 %18, 20
br i1 %19, label %20, label %31
20: ; preds = %17
%21 = load i32, i32* %4
%22 = load i32, i32* %4
%23 = sub nsw i32 19, %22
%24 = sext i32 %23 to i64
%25 = getelementptr inbounds [20 x i32], [20 x i32]* %2, i64 0, i64 %24
%26 = load i32, i32* %25
%27 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %21, i32 %26)
br label %28
28: ; preds = %20
%29 = load i32, i32* %4
%30 = add nsw i32 %29, 1
store i32 %30, i32* %4
br label %17
31: ; preds = %17
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [12 x i8] c"N[%d] = %d\0A\00"
define i32 @main() {
%1 = alloca [20 x i32]
%2 = bitcast [20 x i32]* %1 to i8*
%3 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 0
%4 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %3)
%5 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 1
%6 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %5)
%7 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 2
%8 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %7)
%9 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 3
%10 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %9)
%11 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 4
%12 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %11)
%13 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 5
%14 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %13)
%15 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 6
%16 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %15)
%17 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 7
%18 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %17)
%19 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 8
%20 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %19)
%21 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 9
%22 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %21)
%23 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 10
%24 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %23)
%25 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 11
%26 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %25)
%27 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 12
%28 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %27)
%29 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 13
%30 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %29)
%31 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 14
%32 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %31)
%33 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 15
%34 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %33)
%35 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 16
%36 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %35)
%37 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 17
%38 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %37)
%39 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 18
%40 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %39)
%41 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 19
%42 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %41)
%43 = load i32, i32* %41
%44 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 0, i32 %43)
%45 = load i32, i32* %39
%46 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 1, i32 %45)
%47 = load i32, i32* %37
%48 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 2, i32 %47)
%49 = load i32, i32* %35
%50 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 3, i32 %49)
%51 = load i32, i32* %33
%52 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 4, i32 %51)
%53 = load i32, i32* %31
%54 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 5, i32 %53)
%55 = load i32, i32* %29
%56 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 6, i32 %55)
%57 = load i32, i32* %27
%58 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 7, i32 %57)
%59 = load i32, i32* %25
%60 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 8, i32 %59)
%61 = load i32, i32* %23
%62 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 9, i32 %61)
%63 = load i32, i32* %21
%64 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 10, i32 %63)
%65 = load i32, i32* %19
%66 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 11, i32 %65)
%67 = load i32, i32* %17
%68 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 12, i32 %67)
%69 = load i32, i32* %15
%70 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 13, i32 %69)
%71 = load i32, i32* %13
%72 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 14, i32 %71)
%73 = load i32, i32* %11
%74 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 15, i32 %73)
%75 = load i32, i32* %9
%76 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 16, i32 %75)
%77 = load i32, i32* %7
%78 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 17, i32 %77)
%79 = load i32, i32* %5
%80 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 18, i32 %79)
%81 = load i32, i32* %3
%82 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 19, i32 %81)
ret i32 0
}